@usecapsule/core-components 3.0.1 → 3.1.1
Sign up to get free protection for your applications and to get access to all the features.
- package/css/capsule-core.css +93 -24
- package/css/capsule-core.css.map +1 -1
- package/dist/capsule/capsule.esm.js +1 -1
- package/dist/capsule/capsule.esm.js.map +1 -1
- package/dist/capsule/index.esm.js +1 -1
- package/dist/capsule/index.esm.js.map +1 -1
- package/dist/capsule/p-02072c68.entry.js +2 -0
- package/dist/capsule/p-02072c68.entry.js.map +1 -0
- package/dist/capsule/p-1474c545.entry.js +29 -0
- package/dist/capsule/p-1474c545.entry.js.map +1 -0
- package/dist/capsule/p-2c16694d.entry.js +2 -0
- package/dist/capsule/p-41088cd4.entry.js +2 -0
- package/dist/capsule/{p-fcead80b.entry.js.map → p-41088cd4.entry.js.map} +1 -1
- package/dist/capsule/{p-fa078837.entry.js → p-6dcaee48.entry.js} +2 -2
- package/dist/capsule/p-7dde3172.js +3 -0
- package/dist/capsule/p-7dde3172.js.map +1 -0
- package/dist/capsule/{p-d28b96ba.entry.js → p-a6aaf3f4.entry.js} +2 -2
- package/dist/capsule/{p-0d0a0037.entry.js → p-b976b6f0.entry.js} +2 -2
- package/dist/capsule/p-f2393be6.js +2 -0
- package/dist/capsule/p-f2393be6.js.map +1 -0
- package/dist/cjs/capsule.cjs.js +2 -2
- package/dist/cjs/{constants-0869a780.js → constants-9b1b01bb.js} +3 -3
- package/dist/cjs/{constants-0869a780.js.map → constants-9b1b01bb.js.map} +1 -1
- package/dist/cjs/{cpsl-alert_29.cjs.entry.js → cpsl-alert_33.cjs.entry.js} +662 -87
- package/dist/cjs/cpsl-alert_33.cjs.entry.js.map +1 -0
- package/dist/cjs/cpsl-animation.cjs.entry.js +1 -1
- package/dist/cjs/cpsl-col.cjs.entry.js +1 -1
- package/dist/cjs/cpsl-grid.cjs.entry.js +3 -3
- package/dist/cjs/cpsl-info-box.cjs.entry.js +3 -3
- package/dist/cjs/cpsl-info-box.cjs.entry.js.map +1 -1
- package/dist/cjs/cpsl-modal-v2.cjs.entry.js +55 -0
- package/dist/cjs/cpsl-modal-v2.cjs.entry.js.map +1 -0
- package/dist/cjs/cpsl-row.cjs.entry.js +2 -2
- package/dist/cjs/{index-5733071e.js → index-528f7428.js} +86 -3
- package/dist/cjs/index-528f7428.js.map +1 -0
- package/dist/cjs/index.cjs.js +116 -107
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/assets/icons/chevron-up.svg +2 -2
- package/dist/collection/assets/icons/close.svg +3 -4
- package/dist/collection/assets/icons/cube.svg +3 -0
- package/dist/collection/assets/icons/farcaster-brand.svg +10 -0
- package/dist/collection/assets/icons/farcaster.svg +10 -0
- package/dist/collection/assets/icons/image.svg +3 -0
- package/dist/collection/assets/icons/index.js +9 -1
- package/dist/collection/assets/icons/index.js.map +1 -1
- package/dist/collection/assets/icons/menu.svg +3 -0
- package/dist/collection/assets/icons/refresh.svg +3 -0
- package/dist/collection/assets/icons/stars.svg +4 -0
- package/dist/collection/assets/icons/x.svg +3 -0
- package/dist/collection/collection-manifest.json +5 -0
- package/dist/collection/components/cpsl-alert/cpsl-alert.js +1 -1
- package/dist/collection/components/cpsl-app-bar/cpsl-app-bar.js +20 -4
- package/dist/collection/components/cpsl-app-bar/cpsl-app-bar.js.map +1 -1
- package/dist/collection/components/cpsl-button/cpsl-button.css +113 -17
- package/dist/collection/components/cpsl-button/cpsl-button.js +63 -7
- package/dist/collection/components/cpsl-button/cpsl-button.js.map +1 -1
- package/dist/collection/components/cpsl-button-group/cpsl-button-group.css +1 -0
- package/dist/collection/components/cpsl-card/cpsl-card.css +1 -1
- package/dist/collection/components/cpsl-card/cpsl-card.js +1 -1
- package/dist/collection/components/cpsl-card/cpsl-card.js.map +1 -1
- package/dist/collection/components/cpsl-checkbox/cpsl-checkbox.css +2 -2
- package/dist/collection/components/cpsl-code-input/cpsl-code-input.css +1 -1
- package/dist/collection/components/cpsl-divider/cpsl-divider.css +1 -1
- package/dist/collection/components/cpsl-drawer/cpsl-drawer.js +84 -11
- package/dist/collection/components/cpsl-drawer/cpsl-drawer.js.map +1 -1
- package/dist/collection/components/cpsl-dropdown/cpsl-dropdown.js +1 -1
- package/dist/collection/components/cpsl-dropdown/cpsl-dropdown.js.map +1 -1
- package/dist/collection/components/cpsl-file-upload/cpsl-file-upload.css +211 -0
- package/dist/collection/components/cpsl-file-upload/cpsl-file-upload.js +406 -0
- package/dist/collection/components/cpsl-file-upload/cpsl-file-upload.js.map +1 -0
- package/dist/collection/components/cpsl-file-upload/test/cpsl-file-upload.e2e.js +29 -0
- package/dist/collection/components/cpsl-file-upload/test/cpsl-file-upload.e2e.js.map +1 -0
- package/dist/collection/components/cpsl-file-upload/test/cpsl-file-upload.spec.js +37 -0
- package/dist/collection/components/cpsl-file-upload/test/cpsl-file-upload.spec.js.map +1 -0
- package/dist/collection/components/cpsl-grid/cpsl-grid.js +2 -2
- package/dist/collection/components/cpsl-icon/cpsl-icon.js +2 -2
- package/dist/collection/components/cpsl-info-box/cpsl-info-box.css +1 -1
- package/dist/collection/components/cpsl-info-box/cpsl-info-box.js +1 -1
- package/dist/collection/components/cpsl-input/cpsl-input.css +7 -6
- package/dist/collection/components/cpsl-input/cpsl-input.js +3 -8
- package/dist/collection/components/cpsl-input/cpsl-input.js.map +1 -1
- package/dist/collection/components/cpsl-modal/cpsl-modal.css +4 -4
- package/dist/collection/components/cpsl-modal/cpsl-modal.js +1 -0
- package/dist/collection/components/cpsl-modal/cpsl-modal.js.map +1 -1
- package/dist/collection/components/cpsl-modal-v2/cpsl-modal-v2.css +91 -0
- package/dist/collection/components/cpsl-modal-v2/cpsl-modal-v2.js +224 -0
- package/dist/collection/components/cpsl-modal-v2/cpsl-modal-v2.js.map +1 -0
- package/dist/collection/components/cpsl-modal-v2/test/cpsl-modal-v2.e2e.js +29 -0
- package/dist/collection/components/cpsl-modal-v2/test/cpsl-modal-v2.e2e.js.map +1 -0
- package/dist/collection/components/cpsl-modal-v2/test/cpsl-modal-v2.spec.js +37 -0
- package/dist/collection/components/cpsl-modal-v2/test/cpsl-modal-v2.spec.js.map +1 -0
- package/dist/collection/components/cpsl-nav-button-group/cpsl-nav-button-group.js +1 -1
- package/dist/collection/components/cpsl-overlay/cpsl-overlay.css +1 -1
- package/dist/collection/components/cpsl-overlay/cpsl-overlay.js +1 -1
- package/dist/collection/components/cpsl-pagination/cpsl-pagination.css +4 -0
- package/dist/collection/components/cpsl-pagination/cpsl-pagination.js +1 -1
- package/dist/collection/components/cpsl-pagination/cpsl-pagination.js.map +1 -1
- package/dist/collection/components/cpsl-pill/cpsl-pill.css +1 -1
- package/dist/collection/components/cpsl-pill/cpsl-pill.js +1 -1
- package/dist/collection/components/cpsl-popover/cpsl-popover.css +98 -0
- package/dist/collection/components/cpsl-popover/cpsl-popover.js +511 -0
- package/dist/collection/components/cpsl-popover/cpsl-popover.js.map +1 -0
- package/dist/collection/components/cpsl-popover/test/cpsl-popover.e2e.js +29 -0
- package/dist/collection/components/cpsl-popover/test/cpsl-popover.e2e.js.map +1 -0
- package/dist/collection/components/cpsl-popover/test/cpsl-popover.spec.js +37 -0
- package/dist/collection/components/cpsl-popover/test/cpsl-popover.spec.js.map +1 -0
- package/dist/collection/components/cpsl-progress-indicator/cpsl-progress-indicator.css +3 -3
- package/dist/collection/components/cpsl-qr-code/cpsl-qr-code.css +1 -1
- package/dist/collection/components/cpsl-qr-code/cpsl-qr-code.js +1 -1
- package/dist/collection/components/cpsl-radio/cpsl-radio.css +2 -2
- package/dist/collection/components/cpsl-radio/cpsl-radio.js +1 -1
- package/dist/collection/components/cpsl-row/cpsl-row.js +1 -1
- package/dist/collection/components/cpsl-select/cpsl-select.css +229 -0
- package/dist/collection/components/cpsl-select/cpsl-select.js +409 -0
- package/dist/collection/components/cpsl-select/cpsl-select.js.map +1 -0
- package/dist/collection/components/cpsl-select/test/cpsl-select.e2e.js +29 -0
- package/dist/collection/components/cpsl-select/test/cpsl-select.e2e.js.map +1 -0
- package/dist/collection/components/cpsl-select/test/cpsl-select.spec.js +37 -0
- package/dist/collection/components/cpsl-select/test/cpsl-select.spec.js.map +1 -0
- package/dist/collection/components/cpsl-select-item/cpsl-select-item.css +114 -0
- package/dist/collection/components/cpsl-select-item/cpsl-select-item.js +85 -0
- package/dist/collection/components/cpsl-select-item/cpsl-select-item.js.map +1 -0
- package/dist/collection/components/cpsl-select-item/test/cpsl-select-item.e2e.js +29 -0
- package/dist/collection/components/cpsl-select-item/test/cpsl-select-item.e2e.js.map +1 -0
- package/dist/collection/components/cpsl-select-item/test/cpsl-select-item.spec.js +37 -0
- package/dist/collection/components/cpsl-select-item/test/cpsl-select-item.spec.js.map +1 -0
- package/dist/collection/components/cpsl-slide-button/cpsl-slide-button.css +3 -3
- package/dist/collection/components/cpsl-slide-button/cpsl-slide-button.js +3 -3
- package/dist/collection/components/cpsl-spinner/cpsl-spinner.js +2 -2
- package/dist/collection/components/cpsl-switch/cpsl-switch.css +4 -4
- package/dist/collection/components/cpsl-switch/cpsl-switch.js +1 -1
- package/dist/collection/components/cpsl-tab/cpsl-tab.js +1 -1
- package/dist/collection/components/cpsl-table/cpsl-table.css +40 -60
- package/dist/collection/components/cpsl-table/cpsl-table.js +40 -58
- package/dist/collection/components/cpsl-table/cpsl-table.js.map +1 -1
- package/dist/collection/components/cpsl-tabs/cpsl-tabs.css +2 -2
- package/dist/collection/components/cpsl-tabs/cpsl-tabs.js +1 -1
- package/dist/collection/components/cpsl-text/cpsl-text.css +4 -0
- package/dist/collection/components/cpsl-text/cpsl-text.js +5 -4
- package/dist/collection/components/cpsl-text/cpsl-text.js.map +1 -1
- package/dist/collection/components/cpsl-tile-button/cpsl-tile-button.css +1 -1
- package/dist/collection/components/cpsl-tile-button/cpsl-tile-button.js +2 -2
- package/dist/collection/constants.js +2 -2
- package/dist/collection/constants.js.map +1 -1
- package/dist/collection/interface.js.map +1 -1
- package/dist/collection/utils/theme/generateBorderRadii.js +40 -39
- package/dist/collection/utils/theme/generateBorderRadii.js.map +1 -1
- package/dist/collection/utils/theme/generatePalette.js +11 -3
- package/dist/collection/utils/theme/generatePalette.js.map +1 -1
- package/dist/collection/utils/theme/generateTheme.js +2 -2
- package/dist/collection/utils/theme/generateTheme.js.map +1 -1
- package/dist/collection/utils/theme/utils.js +1 -0
- package/dist/collection/utils/theme/utils.js.map +1 -1
- package/dist/esm/capsule.js +3 -3
- package/dist/esm/{constants-6acf4ea8.js → constants-fce138fa.js} +3 -3
- package/dist/esm/{constants-6acf4ea8.js.map → constants-fce138fa.js.map} +1 -1
- package/dist/esm/{cpsl-alert_29.entry.js → cpsl-alert_33.entry.js} +659 -88
- package/dist/esm/cpsl-alert_33.entry.js.map +1 -0
- package/dist/esm/cpsl-animation.entry.js +1 -1
- package/dist/esm/cpsl-col.entry.js +1 -1
- package/dist/esm/cpsl-grid.entry.js +3 -3
- package/dist/esm/cpsl-info-box.entry.js +3 -3
- package/dist/esm/cpsl-info-box.entry.js.map +1 -1
- package/dist/esm/cpsl-modal-v2.entry.js +51 -0
- package/dist/esm/cpsl-modal-v2.entry.js.map +1 -0
- package/dist/esm/cpsl-row.entry.js +2 -2
- package/dist/esm/{index-8fe9f35e.js → index-b188f201.js} +86 -4
- package/dist/esm/index-b188f201.js.map +1 -0
- package/dist/esm/index.js +116 -107
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/types/assets/icons/index.d.ts +8 -0
- package/dist/types/components/cpsl-app-bar/cpsl-app-bar.d.ts +1 -0
- package/dist/types/components/cpsl-button/cpsl-button.d.ts +4 -1
- package/dist/types/components/cpsl-drawer/cpsl-drawer.d.ts +10 -1
- package/dist/types/components/cpsl-file-upload/cpsl-file-upload.d.ts +34 -0
- package/dist/types/components/cpsl-input/cpsl-input.d.ts +1 -1
- package/dist/types/components/cpsl-modal-v2/cpsl-modal-v2.d.ts +17 -0
- package/dist/types/components/cpsl-popover/cpsl-popover.d.ts +35 -0
- package/dist/types/components/cpsl-select/cpsl-select.d.ts +38 -0
- package/dist/types/components/cpsl-select-item/cpsl-select-item.d.ts +8 -0
- package/dist/types/components/cpsl-table/cpsl-table.d.ts +8 -3
- package/dist/types/components/cpsl-text/cpsl-text.d.ts +1 -1
- package/dist/types/components.d.ts +596 -28
- package/dist/types/constants.d.ts +2 -2
- package/dist/types/interface.d.ts +68 -1
- package/dist/types/utils/theme/generateBorderRadii.d.ts +1 -1
- package/dist/types/utils/theme/generateTheme.d.ts +1 -1
- package/dist/types/utils/theme/utils.d.ts +4 -1
- package/package.json +2 -2
- package/dist/capsule/p-107e1ff5.entry.js +0 -29
- package/dist/capsule/p-107e1ff5.entry.js.map +0 -1
- package/dist/capsule/p-86e48e61.js +0 -3
- package/dist/capsule/p-86e48e61.js.map +0 -1
- package/dist/capsule/p-ad14a817.entry.js +0 -2
- package/dist/capsule/p-b6b38e73.js +0 -2
- package/dist/capsule/p-b6b38e73.js.map +0 -1
- package/dist/capsule/p-fcead80b.entry.js +0 -2
- package/dist/cjs/cpsl-alert_29.cjs.entry.js.map +0 -1
- package/dist/cjs/index-5733071e.js.map +0 -1
- package/dist/collection/components/cpsl-table/table-interface.js +0 -2
- package/dist/collection/components/cpsl-table/table-interface.js.map +0 -1
- package/dist/esm/cpsl-alert_29.entry.js.map +0 -1
- package/dist/esm/index-8fe9f35e.js.map +0 -1
- package/dist/types/components/cpsl-table/table-interface.d.ts +0 -19
- /package/dist/capsule/{p-ad14a817.entry.js.map → p-2c16694d.entry.js.map} +0 -0
- /package/dist/capsule/{p-fa078837.entry.js.map → p-6dcaee48.entry.js.map} +0 -0
- /package/dist/capsule/{p-d28b96ba.entry.js.map → p-a6aaf3f4.entry.js.map} +0 -0
- /package/dist/capsule/{p-0d0a0037.entry.js.map → p-b976b6f0.entry.js.map} +0 -0
@@ -15,8 +15,31 @@ export type Theme = {
|
|
15
15
|
font?: string;
|
16
16
|
customPalette?: CustomPalette;
|
17
17
|
customFontSizes?: CustomFontSizes;
|
18
|
+
customBorderRadii?: CustomBorderRadii;
|
18
19
|
};
|
19
|
-
export type BorderRadius = 'none' | 'xs' | 'sm' | 'md' | 'lg' | 'full';
|
20
|
+
export type BorderRadius = 'none' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'full';
|
21
|
+
export interface CustomBorderRadii {
|
22
|
+
input?: string;
|
23
|
+
select?: string;
|
24
|
+
fileSelect?: string;
|
25
|
+
alert?: string;
|
26
|
+
tabs?: string;
|
27
|
+
primaryButton?: string;
|
28
|
+
secondaryButton?: string;
|
29
|
+
destructiveButton?: string;
|
30
|
+
tileButton?: string;
|
31
|
+
modal?: string;
|
32
|
+
pill?: string;
|
33
|
+
qrCode?: string;
|
34
|
+
infoBox?: string;
|
35
|
+
tableContainer?: string;
|
36
|
+
switch?: string;
|
37
|
+
checkbox?: string;
|
38
|
+
radio?: string;
|
39
|
+
avatar?: string;
|
40
|
+
card?: string;
|
41
|
+
buttonGroup?: string;
|
42
|
+
}
|
20
43
|
export interface CustomFontSizes {
|
21
44
|
body2XS?: string;
|
22
45
|
bodyXS?: string;
|
@@ -50,6 +73,7 @@ export interface CustomPalette {
|
|
50
73
|
surface?: {
|
51
74
|
disabled?: string;
|
52
75
|
default?: string;
|
76
|
+
hover?: string;
|
53
77
|
};
|
54
78
|
border?: {
|
55
79
|
placeholder?: string;
|
@@ -57,6 +81,32 @@ export interface CustomPalette {
|
|
57
81
|
error?: string;
|
58
82
|
};
|
59
83
|
};
|
84
|
+
select?: {
|
85
|
+
surface?: {
|
86
|
+
disabled?: string;
|
87
|
+
default?: string;
|
88
|
+
hover?: string;
|
89
|
+
};
|
90
|
+
border?: {
|
91
|
+
placeholder?: string;
|
92
|
+
active?: string;
|
93
|
+
error?: string;
|
94
|
+
};
|
95
|
+
dropdown?: {
|
96
|
+
border?: string;
|
97
|
+
};
|
98
|
+
};
|
99
|
+
file?: {
|
100
|
+
surface?: {
|
101
|
+
disabled?: string;
|
102
|
+
default?: string;
|
103
|
+
drag?: string;
|
104
|
+
};
|
105
|
+
border?: {
|
106
|
+
placeholder?: string;
|
107
|
+
error?: string;
|
108
|
+
};
|
109
|
+
};
|
60
110
|
tileButton?: {
|
61
111
|
surface?: {
|
62
112
|
default?: string;
|
@@ -91,6 +141,19 @@ export interface CustomPalette {
|
|
91
141
|
};
|
92
142
|
outline?: string;
|
93
143
|
};
|
144
|
+
destructiveButton?: {
|
145
|
+
surface?: {
|
146
|
+
default?: string;
|
147
|
+
hover?: string;
|
148
|
+
pressed?: string;
|
149
|
+
disabled?: string;
|
150
|
+
};
|
151
|
+
border?: {
|
152
|
+
default?: string;
|
153
|
+
disabled?: string;
|
154
|
+
};
|
155
|
+
outline?: string;
|
156
|
+
};
|
94
157
|
divider?: string;
|
95
158
|
spinner?: {
|
96
159
|
path?: string;
|
@@ -180,3 +243,7 @@ export interface CustomPalette {
|
|
180
243
|
border?: string;
|
181
244
|
};
|
182
245
|
}
|
246
|
+
export interface InteractionCallback {
|
247
|
+
eventName: string;
|
248
|
+
callback: (ev: any) => void;
|
249
|
+
}
|
@@ -1,2 +1,2 @@
|
|
1
1
|
import { Theme } from '../../interface';
|
2
|
-
export declare const generateBorderRadii: ({ borderRadius }: Pick<Theme, 'borderRadius'>) => void;
|
2
|
+
export declare const generateBorderRadii: ({ borderRadius, customBorderRadii }: Pick<Theme, 'borderRadius' | 'customBorderRadii'>) => void;
|
@@ -1,2 +1,2 @@
|
|
1
1
|
import { Theme } from '../../interface';
|
2
|
-
export declare const generateTheme: ({ foregroundColor, backgroundColor, font, customPalette, borderRadius, customFontSizes, }: Theme) => boolean;
|
2
|
+
export declare const generateTheme: ({ foregroundColor, backgroundColor, font, customPalette, borderRadius, customFontSizes, customBorderRadii, }: Theme) => boolean;
|
@@ -1,6 +1,9 @@
|
|
1
|
-
import { CustomPalette } from '../../interface';
|
1
|
+
import { CustomBorderRadii, CustomPalette } from '../../interface';
|
2
2
|
export declare const isColor: (strColor: any) => boolean;
|
3
3
|
export declare const getCssColors: (customPalette: CustomPalette) => {
|
4
4
|
[k: string]: string;
|
5
5
|
};
|
6
|
+
export declare const getCssBorderRadii: (customBorderRadii: CustomBorderRadii) => {
|
7
|
+
[k: string]: string;
|
8
|
+
};
|
6
9
|
export declare const overlayMix: (baseColor: string, overlayColor: string) => string;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@usecapsule/core-components",
|
3
|
-
"version": "3.
|
3
|
+
"version": "3.1.1",
|
4
4
|
"description": "Capsule Core Components",
|
5
5
|
"main": "dist/index.cjs.js",
|
6
6
|
"module": "dist/index.js",
|
@@ -51,5 +51,5 @@
|
|
51
51
|
"stencil-inline-svg": "^1.1.0",
|
52
52
|
"ts-node": "^10.9.2"
|
53
53
|
},
|
54
|
-
"gitHead": "
|
54
|
+
"gitHead": "218adf71219748753bb71aed7d7c106d05b6d974"
|
55
55
|
}
|