✨ Add Chip component
Chip comes in neutral and action variants and supports a removable state with a delete button. Includes styles and barrel exports.
This commit is contained in:
1 parent
f9489fdffc
commit
df47b69155
5 files changed
+105
No files matched your search
@@ -0,0 +1,50 @@
|
||||
/**
|
||||
* Chip
|
||||
*/
|
||||
|
||||
.navds-chip {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: var(--a-spacing-1);
|
||||
padding: var(--a-spacing-1) var(--a-spacing-3);
|
||||
border: 1px solid var(--a-border-default);
|
||||
border-radius: var(--a-border-radius-full);
|
||||
background-color: var(--a-bg-default);
|
||||
color: var(--a-text-default);
|
||||
font-family: var(--a-font-family);
|
||||
font-size: var(--a-font-size-xs);
|
||||
}
|
||||
|
||||
.navds-chip--action {
|
||||
border-color: var(--a-border-action);
|
||||
background-color: var(--a-surface-action);
|
||||
color: var(--a-text-on-action);
|
||||
}
|
||||
|
||||
.navds-chip--action:hover {
|
||||
background-color: var(--a-surface-action-hover);
|
||||
}
|
||||
|
||||
.navds-chip--removable {
|
||||
padding-right: var(--a-spacing-1);
|
||||
}
|
||||
|
||||
.navds-chip__delete {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
padding: 2px;
|
||||
border: none;
|
||||
border-radius: var(--a-border-radius-full);
|
||||
background-color: transparent;
|
||||
color: inherit;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.navds-chip__delete:hover {
|
||||
background-color: rgb(35 38 42 / 15%);
|
||||
}
|
||||
|
||||
.navds-chip:focus-within {
|
||||
outline: 2px solid var(--a-border-focus);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
@@ -6,3 +6,4 @@
|
||||
@import "./alert.css";
|
||||
@import "./accordion.css";
|
||||
@import "./modal.css";
|
||||
@import "./chip.css";
|
||||
Reference in new issue
Block a user