Giter Site home page Giter Site logo

primer-button-element's Introduction

Pink glittery and 'jittery' text that can only be described as 'overly cute'. The text reads 'Welcome to my profile!'

primer-button-element's People

Contributors

koddsson avatar

Watchers

 avatar

primer-button-element's Issues

Investigate ways include the CSS needed from a CSS file.

Having the CSS included in the component as an HTML string with a <style> tag is probably not very performant and is not very developer-friendly.

Having the CSS in a CSS file means you get IDE code highlighting and lining.

To summarize:

  • I want CSS linting and code highlighting from most editors.
    • The solution to this is probably having the CSS in a separate file.
  • I want the CSS to load as fast as possible.
    • Problem is that I don't know how to measure this. What even is fast enough here?
    • Maybe research loading patterns for CSS. CSS can maybe be loaded dynamically??
  • Avoiding build steps as much as possible would be great but maybe unavoidable?

:host {
--color-btn-bg: #f6f8fa;
--color-btn-border: rgba(27,31,36,0.15);
--color-btn-focus-border: rgba(27,31,36,0.15);
--color-btn-focus-shadow: 0 0 0 3px rgba(9,105,218,0.3);
--color-btn-hover-bg: #f3f4f6;
--color-btn-hover-border: rgba(27,31,36,0.15);
--color-btn-inset-shadow: inset 0 1px 0 rgba(255,255,255,0.25);
--color-btn-shadow: 0 1px 0 rgba(27,31,36,0.04);
--color-btn-text: #24292f;
}
button {
position: relative;
display: inline-block;
padding: 5px 16px;
font-size: 14px;
font-weight: 500;
line-height: 20px;
white-space: nowrap;
vertical-align: middle;
cursor: pointer;
user-select: none;
border: 1px solid var(--color-btn-border);
border-radius: 6px;
appearance: none;
}
button {
color: var(--color-btn-text);
background-color: var(--color-btn-bg);
box-shadow: var(--color-btn-shadow),var(--color-btn-inset-shadow);
transition: .2s cubic-bezier(0.3, 0, 0.5, 1);
transition-property: color,background-color,border-color;
font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"
}
button:hover {
background-color: var(--color-btn-hover-bg);
border-color: var(--color-btn-hover-border);
transition-duration: 0.1s;
}
button:focus {
border-color: var(--color-btn-focus-border);
outline: none;
box-shadow: var(--color-btn-focus-shadow);
}
:host([primary]) button {
--color-btn-text: #ffffff;
--color-btn-bg: #2da44e;
--color-btn-border: rgba(27,31,36,0.15);
--color-btn-shadow: 0 1px 0 rgba(27,31,36,0.1);
--color-btn-inset-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
}
:host([primary]) button:hover {
--color-btn-hover-bg: #2c974b;
--color-btn-hover-border: rgba(27,31,36,0.15);
}
:host([primary][disabled]) button:hover {
--color-btn-hover-text: rgba(255,255,255,0.8);
--color-btn-hover-bg: #94d3a2;
--color-btn-border: rgba(27,31,36,0.15);
}
:host([disabled]) button {
--color-btn-text: #8c959f;
}
:host([disabled][primary]) button {
--color-btn-text: rgba(255,255,255,0.8);
--color-btn-bg: #94d3a2;
}
.btn:disabled, .btn.disabled, .btn[aria-disabled=true] {
cursor: default;
}

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.