Coder Social home page Coder Social logo

superellipse-css's Introduction

超橢圓 CSS 懶人包

正當大家都興高采烈打開 Photoshop/Figma 按照「超橢圓」修改自己 Logo,我們發現很多公司還未沒有跟隨改變 Logo 🥺!!肯定是 border-radius 大法被笑得狠,IT 部門又未收到新圖檔,所以,我們推出了【超橢圓 CSS 懶人包】!來!把所有的 Logo 都變成「超橢圓」吧!!!

用法

把以下一段 CSS 貼到任何 HTML element 當中,便可以看到「 超橢圓」!當然,只有方形的 Logo 才能使用這個懶人包啊!

  mask: url('data:image/svg+xml;utf8,<svg preserveAspectRatio="none" viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"><path d="M 0, 100 C 0, 23 23, 0 100, 0 S 200, 23 200, 100 177, 200 100, 200 0, 177 0, 100" fill="white"></path></svg>');
  mask-size: 100% 100%;
  -webkit-mask-image: url('data:image/svg+xml;utf8,<svg preserveAspectRatio="none" viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"><path d="M 0, 100 C 0, 23 23, 0 100, 0 S 200, 23 200, 100 177, 200 100, 200 0, 177 0, 100" fill="white"></path></svg>');
  border-radius: 0;

示範

懶人包示範

授權

MIT

superellipse-css's People

Contributors

alexlau811 avatar tecky-dev avatar

Stargazers

vonnelu avatar 张洪Heo avatar Rhuzerv avatar Xheowan avatar Ray avatar

Watchers

James Cloos avatar Gordon Lau Wai Chung avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.