@mozaic-ds/web-components 1.0.0-alpha.4 → 1.0.0-alpha.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.js +31 -0
- package/dist/components/badge/Badge.svelte +35 -3
- package/dist/components/badge/Badge.svelte.d.ts +10 -0
- package/dist/components/badge/Badge.svelte.d.ts.map +1 -0
- package/dist/components/badge/badge.types.d.ts +3 -0
- package/dist/components/badge/badge.types.d.ts.map +1 -0
- package/dist/components/badge/badge.types.js +1 -0
- package/dist/components/button/Button.svelte +346 -13
- package/dist/components/button/Button.svelte.d.ts +43 -0
- package/dist/components/button/Button.svelte.d.ts.map +1 -0
- package/dist/components/button/IconButton.svelte +395 -0
- package/dist/components/button/IconButton.svelte.d.ts +15 -0
- package/dist/components/button/IconButton.svelte.d.ts.map +1 -0
- package/dist/components/button/button.types.d.ts +13 -0
- package/dist/components/button/button.types.d.ts.map +1 -0
- package/dist/components/button/button.types.js +1 -0
- package/dist/components/checkbox/Checkbox.svelte +149 -4
- package/dist/components/checkbox/Checkbox.svelte.d.ts +14 -0
- package/dist/components/checkbox/Checkbox.svelte.d.ts.map +1 -0
- package/dist/components/checkboxgroup/checkboxGroup.svelte +149 -4
- package/dist/components/checkboxgroup/checkboxGroup.svelte.d.ts +11 -0
- package/dist/components/checkboxgroup/checkboxGroup.svelte.d.ts.map +1 -0
- package/dist/components/checkboxgroup/checkboxgroup.types.d.ts +11 -0
- package/dist/components/checkboxgroup/checkboxgroup.types.d.ts.map +1 -0
- package/dist/components/checkboxgroup/checkboxgroup.types.js +1 -0
- package/dist/components/field/Field.svelte +78 -3
- package/dist/components/field/Field.svelte.d.ts +40 -0
- package/dist/components/field/Field.svelte.d.ts.map +1 -0
- package/dist/components/link/Link.svelte +70 -3
- package/dist/components/link/Link.svelte.d.ts +42 -0
- package/dist/components/link/Link.svelte.d.ts.map +1 -0
- package/dist/components/link/link.types.d.ts +4 -0
- package/dist/components/link/link.types.d.ts.map +1 -0
- package/dist/components/link/link.types.js +1 -0
- package/dist/components/loader/Loader.svelte +96 -3
- package/dist/components/loader/Loader.svelte.d.ts +11 -0
- package/dist/components/loader/Loader.svelte.d.ts.map +1 -0
- package/dist/components/loader/loader.types.d.ts +3 -0
- package/dist/components/loader/loader.types.d.ts.map +1 -0
- package/dist/components/loader/loader.types.js +1 -0
- package/dist/components/overlay/Overlay.svelte +88 -3
- package/dist/components/overlay/Overlay.svelte.d.ts +32 -0
- package/dist/components/overlay/Overlay.svelte.d.ts.map +1 -0
- package/dist/components/overlay/OverlayLoader.svelte +200 -0
- package/dist/components/overlay/OverlayLoader.svelte.d.ts +9 -0
- package/dist/components/overlay/OverlayLoader.svelte.d.ts.map +1 -0
- package/dist/components/quantityselector/QuantitySelector.svelte +152 -3
- package/dist/components/quantityselector/QuantitySelector.svelte.d.ts +18 -0
- package/dist/components/quantityselector/QuantitySelector.svelte.d.ts.map +1 -0
- package/dist/components/radio/Radio.svelte +75 -3
- package/dist/components/radio/Radio.svelte.d.ts +11 -0
- package/dist/components/radio/Radio.svelte.d.ts.map +1 -0
- package/dist/components/radiogroup/RadioGroup.svelte +151 -4
- package/dist/components/radiogroup/RadioGroup.svelte.d.ts +13 -0
- package/dist/components/radiogroup/RadioGroup.svelte.d.ts.map +1 -0
- package/dist/components/radiogroup/radioGroup.types.d.ts +9 -0
- package/dist/components/radiogroup/radioGroup.types.d.ts.map +1 -0
- package/dist/components/radiogroup/radioGroup.types.js +1 -0
- package/dist/components/select/Select.svelte +62 -3
- package/dist/components/select/Select.svelte.d.ts +16 -0
- package/dist/components/select/Select.svelte.d.ts.map +1 -0
- package/dist/components/select/select.types.d.ts +9 -0
- package/dist/components/select/select.types.d.ts.map +1 -0
- package/dist/components/select/select.types.js +1 -0
- package/dist/components/statusbadge/StatusBadge.svelte +63 -4
- package/dist/components/statusbadge/StatusBadge.svelte.d.ts +32 -0
- package/dist/components/statusbadge/StatusBadge.svelte.d.ts.map +1 -0
- package/dist/components/statusbadge/StatusDot.svelte +49 -0
- package/dist/components/statusbadge/StatusDot.svelte.d.ts +9 -0
- package/dist/components/statusbadge/StatusDot.svelte.d.ts.map +1 -0
- package/dist/components/statusbadge/badge.types.d.ts +3 -0
- package/dist/components/statusbadge/badge.types.d.ts.map +1 -0
- package/dist/components/statusbadge/badge.types.js +1 -0
- package/dist/components/textarea/Textarea.svelte +124 -4
- package/dist/components/textarea/Textarea.svelte.d.ts +32 -0
- package/dist/components/textarea/Textarea.svelte.d.ts.map +1 -0
- package/dist/components/textinput/Textinput.svelte +152 -7
- package/dist/components/textinput/Textinput.svelte.d.ts +41 -0
- package/dist/components/textinput/Textinput.svelte.d.ts.map +1 -0
- package/dist/components/textinput/textinput.types.d.ts +3 -0
- package/dist/components/textinput/textinput.types.d.ts.map +1 -0
- package/dist/components/textinput/textinput.types.js +1 -0
- package/dist/components/toggle/Toggle.svelte +110 -3
- package/dist/components/toggle/Toggle.svelte.d.ts +29 -0
- package/dist/components/toggle/Toggle.svelte.d.ts.map +1 -0
- package/dist/components/toggle/toggle.types.d.ts +2 -0
- package/dist/components/toggle/toggle.types.d.ts.map +1 -0
- package/dist/components/toggle/toggle.types.js +1 -0
- package/dist/main.js +35 -0
- package/dist/stories/Contributing.stories.mdx +1 -0
- package/dist/stories/HowToWrite.stories.mdx +86 -0
- package/dist/stories/Introduction.stories.mdx +131 -0
- package/dist/stories/Status.stories.mdx +56 -0
- package/dist/stories/SupportAndOnboarding.stories.mdx +62 -0
- package/dist/stories/badge/Badge.stories.d.ts +8 -0
- package/dist/stories/badge/Badge.stories.d.ts.map +1 -0
- package/dist/stories/badge/Badge.stories.js +68 -0
- package/dist/stories/button/Button.stories.d.ts +8 -0
- package/dist/stories/button/Button.stories.d.ts.map +1 -0
- package/dist/stories/button/Button.stories.js +151 -0
- package/dist/stories/button/IconButton.stories.d.ts +7 -0
- package/dist/stories/button/IconButton.stories.d.ts.map +1 -0
- package/dist/stories/button/IconButton.stories.js +68 -0
- package/dist/stories/checkbox/Checkbox.stories.d.ts +9 -0
- package/dist/stories/checkbox/Checkbox.stories.d.ts.map +1 -0
- package/dist/stories/checkbox/Checkbox.stories.js +105 -0
- package/dist/stories/checkbox-group/Checkbox-group.stories.d.ts +7 -0
- package/dist/stories/checkbox-group/Checkbox-group.stories.d.ts.map +1 -0
- package/dist/stories/checkbox-group/Checkbox-group.stories.js +140 -0
- package/dist/stories/field/Field.stories.d.ts +10 -0
- package/dist/stories/field/Field.stories.d.ts.map +1 -0
- package/dist/stories/field/Field.stories.js +146 -0
- package/dist/stories/link/Link.stories.d.ts +7 -0
- package/dist/stories/link/Link.stories.d.ts.map +1 -0
- package/dist/stories/link/Link.stories.js +83 -0
- package/dist/stories/loader/Loader.stories.d.ts +7 -0
- package/dist/stories/loader/Loader.stories.d.ts.map +1 -0
- package/dist/stories/loader/Loader.stories.js +52 -0
- package/dist/stories/overlay/Overlay.stories.d.ts +5 -0
- package/dist/stories/overlay/Overlay.stories.d.ts.map +1 -0
- package/dist/stories/overlay/Overlay.stories.js +45 -0
- package/dist/stories/overlay/OverlayLoader.stories.d.ts +5 -0
- package/dist/stories/overlay/OverlayLoader.stories.d.ts.map +1 -0
- package/dist/stories/overlay/OverlayLoader.stories.js +51 -0
- package/dist/stories/quantityselector/QuantitySelector.stories.d.ts +7 -0
- package/dist/stories/quantityselector/QuantitySelector.stories.d.ts.map +1 -0
- package/dist/stories/quantityselector/QuantitySelector.stories.js +124 -0
- package/dist/stories/radio/Radio.stories.d.ts +8 -0
- package/dist/stories/radio/Radio.stories.d.ts.map +1 -0
- package/dist/stories/radio/Radio.stories.js +75 -0
- package/dist/stories/radio-group/Radio-group.stories.d.ts +7 -0
- package/dist/stories/radio-group/Radio-group.stories.d.ts.map +1 -0
- package/dist/stories/radio-group/Radio-group.stories.js +146 -0
- package/dist/stories/select/Select.stories.d.ts +8 -0
- package/dist/stories/select/Select.stories.d.ts.map +1 -0
- package/dist/stories/select/Select.stories.js +88 -0
- package/dist/stories/status-badge/StatusBadge.stories.d.ts +8 -0
- package/dist/stories/status-badge/StatusBadge.stories.d.ts.map +1 -0
- package/dist/stories/status-badge/StatusBadge.stories.js +53 -0
- package/dist/stories/status-dot/StatusDot.stories.d.ts +9 -0
- package/dist/stories/status-dot/StatusDot.stories.d.ts.map +1 -0
- package/dist/stories/status-dot/StatusDot.stories.js +59 -0
- package/dist/stories/textarea/Textarea.stories.d.ts +8 -0
- package/dist/stories/textarea/Textarea.stories.d.ts.map +1 -0
- package/dist/stories/textarea/Textarea.stories.js +97 -0
- package/dist/stories/textinput/Textinput.stories.d.ts +7 -0
- package/dist/stories/textinput/Textinput.stories.d.ts.map +1 -0
- package/dist/stories/textinput/Textinput.stories.js +117 -0
- package/dist/stories/toggle/Toggle.stories.d.ts +8 -0
- package/dist/stories/toggle/Toggle.stories.d.ts.map +1 -0
- package/dist/stories/toggle/Toggle.stories.js +73 -0
- package/dist/utilities/ClickOutside.d.ts +3 -0
- package/dist/utilities/ClickOutside.d.ts.map +1 -0
- package/dist/utilities/ClickOutside.js +13 -0
- package/dist/utilities/EventForward.d.ts +10 -0
- package/dist/utilities/EventForward.d.ts.map +1 -0
- package/dist/utilities/EventForward.js +127 -0
- package/dist/utilities/EventHandler.d.ts +8 -0
- package/dist/utilities/EventHandler.d.ts.map +1 -0
- package/dist/utilities/EventHandler.js +11 -0
- package/package.json +13 -13
- package/dist/Badge.d.ts +0 -5
- package/dist/Button.d.ts +0 -5
- package/dist/Checkbox.d.ts +0 -5
- package/dist/Field.d.ts +0 -5
- package/dist/IconButton.d.ts +0 -5
- package/dist/Link.d.ts +0 -5
- package/dist/Loader.d.ts +0 -5
- package/dist/Overlay.d.ts +0 -5
- package/dist/OverlayLoader.d.ts +0 -5
- package/dist/QuantitySelector.d.ts +0 -5
- package/dist/Radio.d.ts +0 -5
- package/dist/RadioGroup.d.ts +0 -5
- package/dist/Select.d.ts +0 -5
- package/dist/StatusBadge.d.ts +0 -5
- package/dist/StatusDot.d.ts +0 -5
- package/dist/Textarea.d.ts +0 -5
- package/dist/Textinput.d.ts +0 -5
- package/dist/Toggle.d.ts +0 -5
- package/dist/checkboxGroup.d.ts +0 -5
- package/dist/components/badge/Badge.d.ts +0 -4
- package/dist/components/button/Button.d.ts +0 -4
- package/dist/components/button/IconButton.d.ts +0 -4
- package/dist/components/checkbox/Checkbox.d.ts +0 -4
- package/dist/components/checkboxgroup/checkboxGroup.d.ts +0 -4
- package/dist/components/field/Field.d.ts +0 -4
- package/dist/components/iconbutton/IconButton.svelte +0 -62
- package/dist/components/link/Link.d.ts +0 -4
- package/dist/components/loader/Loader.d.ts +0 -4
- package/dist/components/overlay/Overlay.d.ts +0 -4
- package/dist/components/overlay/OverlayLoader.d.ts +0 -4
- package/dist/components/overlayloader/OverlayLoader.svelte +0 -23
- package/dist/components/quantityselector/QuantitySelector.d.ts +0 -4
- package/dist/components/radio/Radio.d.ts +0 -4
- package/dist/components/radiogroup/RadioGroup.d.ts +0 -4
- package/dist/components/select/Select.d.ts +0 -4
- package/dist/components/statusbadge/StatusBadge.d.ts +0 -4
- package/dist/components/statusbadge/StatusDot.d.ts +0 -4
- package/dist/components/statusdot/StatusDot.svelte +0 -22
- package/dist/components/textarea/Textarea.d.ts +0 -4
- package/dist/components/textinput/Textinput.d.ts +0 -4
- package/dist/components/toggle/Toggle.d.ts +0 -4
package/dist/bundle.js
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
|
|
2
|
+
import Button from './components/button/Button.js';
|
|
3
|
+
import IconButton from './components/button/IconButton.js';
|
|
4
|
+
|
|
5
|
+
import Checkbox from './components/checkbox/Checkbox.js';
|
|
6
|
+
import CheckboxGroup from './components/checkboxgroup/checkboxGroup.js';
|
|
7
|
+
import Textarea from './components/textarea/Textarea.js';
|
|
8
|
+
import Select from './components/select/Select.js';
|
|
9
|
+
|
|
10
|
+
import Toggle from './components/toggle/Toggle.js';
|
|
11
|
+
|
|
12
|
+
import Field from './components/field/Field.js';
|
|
13
|
+
|
|
14
|
+
import Link from './components/link/Link.js';
|
|
15
|
+
|
|
16
|
+
import Loader from './components/loader/Loader.js';
|
|
17
|
+
|
|
18
|
+
import Textinput from './components/textinput/Textinput.js';
|
|
19
|
+
|
|
20
|
+
import Overlay from './components/overlay/Overlay.js';
|
|
21
|
+
import OverlayLoader from './components/overlay/OverlayLoader.js';
|
|
22
|
+
|
|
23
|
+
import Radio from './components/radio/Radio.js';
|
|
24
|
+
import RadioGroup from './components/radiogroup/RadioGroup.js';
|
|
25
|
+
|
|
26
|
+
import QuantitySelector from './components/quantityselector/QuantitySelector.js';
|
|
27
|
+
|
|
28
|
+
import Badge from './components/badge/Badge.js';
|
|
29
|
+
import StatusBadge from './components/statusbadge/StatusBadge.js';
|
|
30
|
+
import StatusDot from './components/statusbadge/StatusDot.js';
|
|
31
|
+
|
|
@@ -29,6 +29,38 @@
|
|
|
29
29
|
{label}
|
|
30
30
|
</div>
|
|
31
31
|
|
|
32
|
-
<style
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
<style>/**
|
|
33
|
+
* Do not edit directly, this file was auto-generated.
|
|
34
|
+
*/
|
|
35
|
+
.mc-badge {
|
|
36
|
+
color: var(--badge-color-text-standard, #ffffff);
|
|
37
|
+
background-color: var(--badge-color-background-standard, #464e63);
|
|
38
|
+
height: 1rem;
|
|
39
|
+
min-width: 1rem;
|
|
40
|
+
padding: 0 0.125rem;
|
|
41
|
+
font-size: 0.625rem;
|
|
42
|
+
border-radius: 1rem;
|
|
43
|
+
font-weight: 600;
|
|
44
|
+
display: inline-flex;
|
|
45
|
+
align-items: center;
|
|
46
|
+
box-sizing: border-box;
|
|
47
|
+
justify-content: center;
|
|
48
|
+
}
|
|
49
|
+
.mc-badge--m {
|
|
50
|
+
height: 1.5rem;
|
|
51
|
+
min-width: 1.5rem;
|
|
52
|
+
padding: 0 0.25rem;
|
|
53
|
+
font-size: 0.75rem;
|
|
54
|
+
}
|
|
55
|
+
.mc-badge--accent {
|
|
56
|
+
color: var(--badge-color-text-accent, #ffffff);
|
|
57
|
+
background-color: var(--badge-color-background-accent, #117f03);
|
|
58
|
+
}
|
|
59
|
+
.mc-badge--danger {
|
|
60
|
+
color: var(--badge-color-text-danger, #ffffff);
|
|
61
|
+
background-color: var(--badge-color-background-danger, #c61112);
|
|
62
|
+
}
|
|
63
|
+
.mc-badge--inverse {
|
|
64
|
+
color: var(--badge-color-text-inverse, #464e63);
|
|
65
|
+
background-color: var(--badge-color-background-inverse, #ffffff);
|
|
66
|
+
}</style>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { BadgeStyle, BadgeSize } from './badge.types';
|
|
2
|
+
interface Props {
|
|
3
|
+
label: string;
|
|
4
|
+
style: BadgeStyle;
|
|
5
|
+
size: BadgeSize;
|
|
6
|
+
}
|
|
7
|
+
declare const Badge: import("svelte").Component<Props, {}, "">;
|
|
8
|
+
type Badge = ReturnType<typeof Badge>;
|
|
9
|
+
export default Badge;
|
|
10
|
+
//# sourceMappingURL=Badge.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Badge.svelte.d.ts","sourceRoot":"","sources":["../../../src/components/badge/Badge.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAEzD,UAAU,KAAK;IACb,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,UAAU,CAAC;IAClB,IAAI,EAAE,SAAS,CAAC;CACjB;AAgCH,QAAA,MAAM,KAAK,2CAAsC,CAAC;AAClD,KAAK,KAAK,GAAG,UAAU,CAAC,OAAO,KAAK,CAAC,CAAC;AACtC,eAAe,KAAK,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"badge.types.d.ts","sourceRoot":"","sources":["../../../src/components/badge/badge.types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,UAAU,CAAC;AACtE,MAAM,MAAM,SAAS,GAAG,GAAG,GAAG,GAAG,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -115,19 +115,352 @@
|
|
|
115
115
|
{/if}
|
|
116
116
|
</button>
|
|
117
117
|
|
|
118
|
-
<style
|
|
119
|
-
|
|
118
|
+
<style>/**
|
|
119
|
+
* Do not edit directly, this file was auto-generated.
|
|
120
|
+
*/
|
|
121
|
+
.mc-button {
|
|
122
|
+
color: var(--button-color-filled-standard-font, #ffffff);
|
|
123
|
+
background-color: var(--button-color-filled-standard-background, #464e63);
|
|
124
|
+
font-weight: 600;
|
|
125
|
+
padding: 0 calc(1rem - 0.125rem);
|
|
126
|
+
min-height: 3rem;
|
|
127
|
+
min-width: 3rem;
|
|
128
|
+
display: inline-flex;
|
|
129
|
+
justify-content: center;
|
|
130
|
+
vertical-align: middle;
|
|
131
|
+
text-align: center;
|
|
132
|
+
border: 2px solid transparent;
|
|
133
|
+
border-radius: 0.25rem;
|
|
134
|
+
transition: all ease 200ms;
|
|
135
|
+
transition: box-shadow 200ms ease;
|
|
136
|
+
align-items: center;
|
|
137
|
+
box-sizing: border-box;
|
|
138
|
+
fill: currentcolor;
|
|
139
|
+
gap: 0.25rem;
|
|
140
|
+
cursor: pointer;
|
|
141
|
+
}
|
|
142
|
+
.mc-button:hover {
|
|
143
|
+
background-color: var(--button-color-filled-standard-hover-background, #343b4c);
|
|
144
|
+
}
|
|
145
|
+
.mc-button:active {
|
|
146
|
+
background-color: var(--button-color-filled-standard-active-background, #242938);
|
|
147
|
+
}
|
|
148
|
+
.mc-button:disabled {
|
|
149
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
150
|
+
border-color: transparent;
|
|
151
|
+
color: var(--button-state-disabled-color, #737373);
|
|
152
|
+
cursor: not-allowed;
|
|
153
|
+
}
|
|
154
|
+
.mc-button .mc-button__label {
|
|
155
|
+
font-size: 1rem;
|
|
156
|
+
}
|
|
157
|
+
.mc-button--s {
|
|
158
|
+
padding: 0 calc(0.75rem - 0.125rem);
|
|
159
|
+
min-height: 2rem;
|
|
160
|
+
min-width: 2rem;
|
|
161
|
+
}
|
|
162
|
+
.mc-button--s .mc-button__label {
|
|
163
|
+
font-size: 0.875rem;
|
|
164
|
+
}
|
|
165
|
+
.mc-button--s .mc-button__icon {
|
|
166
|
+
width: 1.25rem;
|
|
167
|
+
height: 1.25rem;
|
|
168
|
+
}
|
|
169
|
+
.mc-button--s .mc-button__icon:only-child {
|
|
170
|
+
width: 1.25rem;
|
|
171
|
+
height: 1.25rem;
|
|
172
|
+
}
|
|
173
|
+
.mc-button--m {
|
|
174
|
+
padding: 0 calc(1rem - 0.125rem);
|
|
175
|
+
min-height: 3rem;
|
|
176
|
+
min-width: 3rem;
|
|
177
|
+
}
|
|
178
|
+
.mc-button--m .mc-button__label {
|
|
179
|
+
font-size: 1rem;
|
|
180
|
+
}
|
|
181
|
+
.mc-button--m .mc-button__icon {
|
|
182
|
+
width: 1.5rem;
|
|
183
|
+
height: 1.5rem;
|
|
184
|
+
}
|
|
185
|
+
.mc-button--m .mc-button__icon:only-child {
|
|
186
|
+
width: 1.5rem;
|
|
187
|
+
height: 1.5rem;
|
|
188
|
+
}
|
|
189
|
+
.mc-button--l {
|
|
190
|
+
padding: 0 calc(1.25rem - 0.125rem);
|
|
191
|
+
min-height: 4rem;
|
|
192
|
+
min-width: 4rem;
|
|
193
|
+
}
|
|
194
|
+
.mc-button--l .mc-button__label {
|
|
195
|
+
font-size: 1.125rem;
|
|
196
|
+
}
|
|
197
|
+
.mc-button--l .mc-button__icon {
|
|
198
|
+
width: 2rem;
|
|
199
|
+
height: 2rem;
|
|
200
|
+
}
|
|
201
|
+
.mc-button--l .mc-button__icon:only-child {
|
|
202
|
+
width: 2rem;
|
|
203
|
+
height: 2rem;
|
|
204
|
+
}
|
|
205
|
+
.mc-button__label {
|
|
206
|
+
font-size: 1rem;
|
|
207
|
+
}
|
|
208
|
+
.mc-button__icon {
|
|
209
|
+
flex-shrink: 0;
|
|
210
|
+
width: 1.5rem;
|
|
211
|
+
height: 1.5rem;
|
|
212
|
+
}
|
|
213
|
+
.mc-button:disabled {
|
|
214
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
215
|
+
border-color: transparent;
|
|
216
|
+
color: var(--button-state-disabled-color, #737373);
|
|
217
|
+
cursor: not-allowed;
|
|
218
|
+
}
|
|
219
|
+
.mc-button:focus-visible {
|
|
220
|
+
box-shadow: 0 0 0 0.125rem var(--focus-color-mid, var(--focus-color-outline-mid, #ffffff)), 0 0 0 0.25rem var(--focus-color-outer, var(--focus-color-outline-outer, #000000));
|
|
221
|
+
outline: 0.125rem solid transparent;
|
|
222
|
+
outline-offset: 0.125rem;
|
|
223
|
+
}
|
|
224
|
+
.mc-button--icon-only {
|
|
225
|
+
padding: 0.25rem;
|
|
226
|
+
}
|
|
227
|
+
.mc-button--outlined {
|
|
228
|
+
color: var(--button-color-outlined-standard-font, #242938);
|
|
229
|
+
border-color: var(--button-color-outlined-standard-border, #8891aa);
|
|
230
|
+
background-color: var(--button-color-outlined-standard-background, #ffffff);
|
|
231
|
+
}
|
|
232
|
+
.mc-button--outlined:hover {
|
|
233
|
+
background-color: var(--button-color-outlined-standard-hover-background, #eff1f6);
|
|
234
|
+
}
|
|
235
|
+
.mc-button--outlined:active {
|
|
236
|
+
background-color: var(--button-color-outlined-standard-active-background, #c9d0de);
|
|
237
|
+
}
|
|
238
|
+
.mc-button--outlined:disabled {
|
|
239
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
240
|
+
border-color: transparent;
|
|
241
|
+
color: var(--button-state-disabled-color, #737373);
|
|
242
|
+
cursor: not-allowed;
|
|
243
|
+
}
|
|
244
|
+
.mc-button--ghost {
|
|
245
|
+
color: var(--button-color-ghost-standard-font, #242938);
|
|
246
|
+
background-color: var(--button-color-ghost-standard-background, rgba(255, 255, 255, 0.01));
|
|
247
|
+
}
|
|
248
|
+
.mc-button--ghost:hover {
|
|
249
|
+
background-color: var(--button-color-ghost-standard-hover-background, rgba(70, 78, 99, 0.1));
|
|
250
|
+
}
|
|
251
|
+
.mc-button--ghost:active {
|
|
252
|
+
background-color: var(--button-color-ghost-standard-active-background, rgba(70, 78, 99, 0.2));
|
|
253
|
+
}
|
|
254
|
+
.mc-button--ghost:disabled {
|
|
255
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
256
|
+
border-color: transparent;
|
|
257
|
+
color: var(--button-state-disabled-color, #737373);
|
|
258
|
+
cursor: not-allowed;
|
|
259
|
+
}
|
|
260
|
+
.mc-button--accent {
|
|
261
|
+
color: var(--button-color-filled-accent-font, #ffffff);
|
|
262
|
+
background-color: var(--button-color-filled-accent-background, #117f03);
|
|
263
|
+
}
|
|
264
|
+
.mc-button--accent:hover {
|
|
265
|
+
background-color: var(--button-color-filled-accent-hover-background, #006902);
|
|
266
|
+
}
|
|
267
|
+
.mc-button--accent:active {
|
|
268
|
+
background-color: var(--button-color-filled-accent-active-background, #035010);
|
|
269
|
+
}
|
|
270
|
+
.mc-button--accent:disabled {
|
|
271
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
272
|
+
border-color: transparent;
|
|
273
|
+
color: var(--button-state-disabled-color, #737373);
|
|
274
|
+
cursor: not-allowed;
|
|
275
|
+
}
|
|
276
|
+
.mc-button--danger {
|
|
277
|
+
color: var(--button-color-filled-danger-font, #ffffff);
|
|
278
|
+
background-color: var(--button-color-filled-danger-background, #c61112);
|
|
279
|
+
}
|
|
280
|
+
.mc-button--danger:hover {
|
|
281
|
+
background-color: var(--button-color-filled-danger-hover-background, #8c0003);
|
|
282
|
+
}
|
|
283
|
+
.mc-button--danger:active {
|
|
284
|
+
background-color: var(--button-color-filled-danger-active-background, #530000);
|
|
285
|
+
}
|
|
286
|
+
.mc-button--danger:disabled {
|
|
287
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
288
|
+
border-color: transparent;
|
|
289
|
+
color: var(--button-state-disabled-color, #737373);
|
|
290
|
+
cursor: not-allowed;
|
|
291
|
+
}
|
|
292
|
+
.mc-button--inverse {
|
|
293
|
+
--focus-color-mid: var(--focus-color-outline-outer, #000000);
|
|
294
|
+
--focus-color-outer: var(--focus-color-outline-mid, #ffffff);
|
|
295
|
+
color: var(--button-color-filled-inverse-font, #242938);
|
|
296
|
+
background-color: var(--button-color-filled-inverse-background, #ffffff);
|
|
297
|
+
}
|
|
298
|
+
.mc-button--inverse:hover {
|
|
299
|
+
background-color: var(--button-color-filled-inverse-hover-background, #e6e6e6);
|
|
300
|
+
}
|
|
301
|
+
.mc-button--inverse:active {
|
|
302
|
+
background-color: var(--button-color-filled-inverse-active-background, #cccccc);
|
|
303
|
+
}
|
|
304
|
+
.mc-button--inverse:disabled {
|
|
305
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
306
|
+
border-color: transparent;
|
|
307
|
+
color: var(--button-state-disabled-color, #737373);
|
|
308
|
+
cursor: not-allowed;
|
|
309
|
+
}
|
|
310
|
+
.mc-button--icon-button {
|
|
311
|
+
border-radius: 100%;
|
|
312
|
+
padding: 0;
|
|
313
|
+
}
|
|
314
|
+
.mc-button--loading .mc-button__loader {
|
|
315
|
+
position: absolute;
|
|
316
|
+
color: currentcolor;
|
|
317
|
+
}
|
|
318
|
+
.mc-button--loading .mc-button__label,
|
|
319
|
+
.mc-button--loading .mc-button__icon {
|
|
320
|
+
visibility: hidden;
|
|
321
|
+
}
|
|
322
|
+
.mc-button--outlined.mc-button--standard {
|
|
323
|
+
color: var(--button-color-outlined-standard-font, #242938);
|
|
324
|
+
border-color: var(--button-color-outlined-standard-border, #8891aa);
|
|
325
|
+
background-color: var(--button-color-outlined-standard-background, #ffffff);
|
|
326
|
+
}
|
|
327
|
+
.mc-button--outlined.mc-button--standard:hover {
|
|
328
|
+
background-color: var(--button-color-outlined-standard-hover-background, #eff1f6);
|
|
329
|
+
}
|
|
330
|
+
.mc-button--outlined.mc-button--standard:active {
|
|
331
|
+
background-color: var(--button-color-outlined-standard-active-background, #c9d0de);
|
|
332
|
+
}
|
|
333
|
+
.mc-button--outlined.mc-button--standard:disabled {
|
|
334
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
335
|
+
border-color: transparent;
|
|
336
|
+
color: var(--button-state-disabled-color, #737373);
|
|
337
|
+
cursor: not-allowed;
|
|
338
|
+
}
|
|
339
|
+
.mc-button--outlined.mc-button--accent {
|
|
340
|
+
color: var(--button-color-outlined-accent-font, #117f03);
|
|
341
|
+
border-color: var(--button-color-outlined-accent-border, #78be20);
|
|
342
|
+
background-color: var(--button-color-outlined-accent-background, #ffffff);
|
|
343
|
+
}
|
|
344
|
+
.mc-button--outlined.mc-button--accent:hover {
|
|
345
|
+
background-color: var(--button-color-outlined-accent-hover-background, #ebf5de);
|
|
346
|
+
}
|
|
347
|
+
.mc-button--outlined.mc-button--accent:active {
|
|
348
|
+
background-color: var(--button-color-outlined-accent-active-background, #c5e39e);
|
|
349
|
+
}
|
|
350
|
+
.mc-button--outlined.mc-button--accent:disabled {
|
|
351
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
352
|
+
border-color: transparent;
|
|
353
|
+
color: var(--button-state-disabled-color, #737373);
|
|
354
|
+
cursor: not-allowed;
|
|
355
|
+
}
|
|
356
|
+
.mc-button--outlined.mc-button--danger {
|
|
357
|
+
color: var(--button-color-outlined-danger-font, #c61112);
|
|
358
|
+
border-color: var(--button-color-outlined-danger-border, #ef5f5c);
|
|
359
|
+
background-color: var(--button-color-outlined-danger-background, #ffffff);
|
|
360
|
+
}
|
|
361
|
+
.mc-button--outlined.mc-button--danger:hover {
|
|
362
|
+
background-color: var(--button-color-outlined-danger-hover-background, #fdeaea);
|
|
363
|
+
}
|
|
364
|
+
.mc-button--outlined.mc-button--danger:active {
|
|
365
|
+
background-color: var(--button-color-outlined-danger-active-background, #f8bcbb);
|
|
366
|
+
}
|
|
367
|
+
.mc-button--outlined.mc-button--danger:disabled {
|
|
368
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
369
|
+
border-color: transparent;
|
|
370
|
+
color: var(--button-state-disabled-color, #737373);
|
|
371
|
+
cursor: not-allowed;
|
|
372
|
+
}
|
|
373
|
+
.mc-button--outlined.mc-button--inverse {
|
|
374
|
+
color: var(--button-color-outlined-inverse-font, #ffffff);
|
|
375
|
+
border-color: var(--button-color-outlined-inverse-border, #ffffff);
|
|
376
|
+
background-color: var(--button-color-outlined-inverse-background, rgba(255, 255, 255, 0.01));
|
|
377
|
+
}
|
|
378
|
+
.mc-button--outlined.mc-button--inverse:hover {
|
|
379
|
+
background-color: var(--button-color-outlined-inverse-hover-background, rgba(255, 255, 255, 0.1));
|
|
380
|
+
}
|
|
381
|
+
.mc-button--outlined.mc-button--inverse:active {
|
|
382
|
+
background-color: var(--button-color-outlined-inverse-active-background, rgba(255, 255, 255, 0.2));
|
|
383
|
+
}
|
|
384
|
+
.mc-button--outlined.mc-button--inverse:disabled {
|
|
385
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
386
|
+
border-color: transparent;
|
|
387
|
+
color: var(--button-state-disabled-color, #737373);
|
|
388
|
+
cursor: not-allowed;
|
|
389
|
+
}
|
|
390
|
+
.mc-button--ghost.mc-button--standard {
|
|
391
|
+
color: var(--button-color-ghost-standard-font, #242938);
|
|
392
|
+
background-color: var(--button-color-ghost-standard-background, rgba(255, 255, 255, 0.01));
|
|
393
|
+
}
|
|
394
|
+
.mc-button--ghost.mc-button--standard:hover {
|
|
395
|
+
background-color: var(--button-color-ghost-standard-hover-background, rgba(70, 78, 99, 0.1));
|
|
396
|
+
}
|
|
397
|
+
.mc-button--ghost.mc-button--standard:active {
|
|
398
|
+
background-color: var(--button-color-ghost-standard-active-background, rgba(70, 78, 99, 0.2));
|
|
399
|
+
}
|
|
400
|
+
.mc-button--ghost.mc-button--standard:disabled {
|
|
401
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
402
|
+
border-color: transparent;
|
|
403
|
+
color: var(--button-state-disabled-color, #737373);
|
|
404
|
+
cursor: not-allowed;
|
|
405
|
+
}
|
|
406
|
+
.mc-button--ghost.mc-button--accent {
|
|
407
|
+
color: var(--button-color-ghost-accent-font, #117f03);
|
|
408
|
+
background-color: var(--button-color-ghost-accent-background, rgba(255, 255, 255, 0.01));
|
|
409
|
+
}
|
|
410
|
+
.mc-button--ghost.mc-button--accent:hover {
|
|
411
|
+
background-color: var(--button-color-ghost-accent-hover-background, rgba(17, 127, 3, 0.1));
|
|
412
|
+
}
|
|
413
|
+
.mc-button--ghost.mc-button--accent:active {
|
|
414
|
+
background-color: var(--button-color-ghost-accent-active-background, rgba(17, 127, 3, 0.2));
|
|
415
|
+
}
|
|
416
|
+
.mc-button--ghost.mc-button--accent:disabled {
|
|
417
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
418
|
+
border-color: transparent;
|
|
419
|
+
color: var(--button-state-disabled-color, #737373);
|
|
420
|
+
cursor: not-allowed;
|
|
421
|
+
}
|
|
422
|
+
.mc-button--ghost.mc-button--danger {
|
|
423
|
+
color: var(--button-color-ghost-danger-font, #c61112);
|
|
424
|
+
background-color: var(--button-color-ghost-danger-background, rgba(255, 255, 255, 0.01));
|
|
425
|
+
}
|
|
426
|
+
.mc-button--ghost.mc-button--danger:hover {
|
|
427
|
+
background-color: var(--button-color-ghost-danger-hover-background, rgba(198, 17, 18, 0.1));
|
|
428
|
+
}
|
|
429
|
+
.mc-button--ghost.mc-button--danger:active {
|
|
430
|
+
background-color: var(--button-color-ghost-danger-active-background, rgba(198, 17, 18, 0.2));
|
|
431
|
+
}
|
|
432
|
+
.mc-button--ghost.mc-button--danger:disabled {
|
|
433
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
434
|
+
border-color: transparent;
|
|
435
|
+
color: var(--button-state-disabled-color, #737373);
|
|
436
|
+
cursor: not-allowed;
|
|
437
|
+
}
|
|
438
|
+
.mc-button--ghost.mc-button--inverse {
|
|
439
|
+
color: var(--button-color-ghost-inverse-font, #ffffff);
|
|
440
|
+
background-color: var(--button-color-ghost-inverse-background, rgba(255, 255, 255, 0.01));
|
|
441
|
+
}
|
|
442
|
+
.mc-button--ghost.mc-button--inverse:hover {
|
|
443
|
+
background-color: var(--button-color-ghost-inverse-hover-background, rgba(255, 255, 255, 0.1));
|
|
444
|
+
}
|
|
445
|
+
.mc-button--ghost.mc-button--inverse:active {
|
|
446
|
+
background-color: var(--button-color-ghost-inverse-active-background, rgba(255, 255, 255, 0.2));
|
|
447
|
+
}
|
|
448
|
+
.mc-button--ghost.mc-button--inverse:disabled {
|
|
449
|
+
background-color: var(--button-state-disabled-background, #d9d9d9);
|
|
450
|
+
border-color: transparent;
|
|
451
|
+
color: var(--button-state-disabled-color, #737373);
|
|
452
|
+
cursor: not-allowed;
|
|
453
|
+
}
|
|
120
454
|
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
455
|
+
.mc-button__icon {
|
|
456
|
+
pointer-events: none;
|
|
457
|
+
}
|
|
124
458
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
459
|
+
.hidden {
|
|
460
|
+
visibility: hidden;
|
|
461
|
+
}
|
|
128
462
|
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
</style>
|
|
463
|
+
.loader-style {
|
|
464
|
+
color: currentColor;
|
|
465
|
+
position: absolute;
|
|
466
|
+
}</style>
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import type { ButtonIconMode, ButtonSize, ButtonStyle, ButtonType } from './button.types';
|
|
2
|
+
interface Props {
|
|
3
|
+
appearance?: ButtonStyle | undefined;
|
|
4
|
+
size?: ButtonSize;
|
|
5
|
+
ghost?: boolean;
|
|
6
|
+
outlined?: boolean;
|
|
7
|
+
iconname: string | undefined;
|
|
8
|
+
iconmode: ButtonIconMode | undefined;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
type?: ButtonType;
|
|
11
|
+
isloading?: boolean;
|
|
12
|
+
[key: string]: any;
|
|
13
|
+
}
|
|
14
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
15
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
16
|
+
$$bindings?: Bindings;
|
|
17
|
+
} & Exports;
|
|
18
|
+
(internal: unknown, props: Props & {
|
|
19
|
+
$$events?: Events;
|
|
20
|
+
$$slots?: Slots;
|
|
21
|
+
}): Exports & {
|
|
22
|
+
$set?: any;
|
|
23
|
+
$on?: any;
|
|
24
|
+
};
|
|
25
|
+
z_$$bindings?: Bindings;
|
|
26
|
+
}
|
|
27
|
+
type $$__sveltets_2_PropsWithChildren<Props, Slots> = Props & (Slots extends {
|
|
28
|
+
default: any;
|
|
29
|
+
} ? Props extends Record<string, never> ? any : {
|
|
30
|
+
children?: any;
|
|
31
|
+
} : {});
|
|
32
|
+
declare const Button: $$__sveltets_2_IsomorphicComponent<$$__sveltets_2_PropsWithChildren<Props, {
|
|
33
|
+
icon: {};
|
|
34
|
+
default: {};
|
|
35
|
+
}>, {
|
|
36
|
+
[evt: string]: CustomEvent<any>;
|
|
37
|
+
}, {
|
|
38
|
+
icon: {};
|
|
39
|
+
default: {};
|
|
40
|
+
}, {}, "">;
|
|
41
|
+
type Button = InstanceType<typeof Button>;
|
|
42
|
+
export default Button;
|
|
43
|
+
//# sourceMappingURL=Button.svelte.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Button.svelte.d.ts","sourceRoot":"","sources":["../../../src/components/button/Button.svelte.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACR,cAAc,EACd,UAAU,EACV,WAAW,EACX,UAAU,EACX,MAAM,gBAAgB,CAAC;AAKxB,UAAU,KAAK;IACb,UAAU,CAAC,EAAE,WAAW,GAAG,SAAS,CAAC;IACrC,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;IAC7B,QAAQ,EAAE,cAAc,GAAG,SAAS,CAAC;IACrC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AA2FH,UAAU,kCAAkC,CAAC,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,GAAG,EAAE,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,GAAG,EAAE,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,GAAG,EAAE,OAAO,GAAG,EAAE,EAAE,QAAQ,GAAG,MAAM;IACpM,KAAK,OAAO,EAAE,OAAO,QAAQ,EAAE,2BAA2B,CAAC,KAAK,CAAC,GAAG,OAAO,QAAQ,EAAE,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,GAAG;QAAE,UAAU,CAAC,EAAE,QAAQ,CAAA;KAAE,GAAG,OAAO,CAAC;IACjK,CAAC,QAAQ,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,GAAG;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,KAAK,CAAA;KAAC,GAAG,OAAO,GAAG;QAAE,IAAI,CAAC,EAAE,GAAG,CAAC;QAAC,GAAG,CAAC,EAAE,GAAG,CAAA;KAAE,CAAC;IAC9G,YAAY,CAAC,EAAE,QAAQ,CAAC;CAC3B;AACD,KAAK,gCAAgC,CAAC,KAAK,EAAE,KAAK,IAAI,KAAK,GACvD,CAAC,KAAK,SAAS;IAAE,OAAO,EAAE,GAAG,CAAA;CAAE,GACzB,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACnC,GAAG,GACH;IAAE,QAAQ,CAAC,EAAE,GAAG,CAAA;CAAE,GAClB,EAAE,CAAC,CAAC;AAId,QAAA,MAAM,MAAM;;;;;;;;UAAmF,CAAC;AAC9E,KAAK,MAAM,GAAG,YAAY,CAAC,OAAO,MAAM,CAAC,CAAC;AAC5C,eAAe,MAAM,CAAC"}
|