@haiilo/catalyst 1.3.1 → 2.0.1
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/catalyst/catalyst.css +1 -1
- package/dist/catalyst/catalyst.esm.js +1 -1
- package/dist/catalyst/catalyst.esm.js.map +1 -1
- package/dist/catalyst/index.cdn.js +10 -6
- package/dist/catalyst/index.esm.js +9 -1
- package/dist/catalyst/index.esm.js.map +1 -1
- package/dist/catalyst/p-167f01e8.entry.js +2 -0
- package/dist/catalyst/p-167f01e8.entry.js.map +1 -0
- package/dist/catalyst/p-5865f232.js +2 -0
- package/dist/catalyst/p-5865f232.js.map +1 -0
- package/dist/catalyst/scss/_variables.scss +1 -1
- package/dist/catalyst/scss/core/_form.scss +8 -0
- package/dist/catalyst/scss/core/_nav.scss +3 -3
- package/dist/catalyst/scss/core/_notification.scss +48 -0
- package/dist/catalyst/scss/index.scss +2 -1
- package/dist/catalyst/scss/utils/_typography.scss +4 -0
- package/dist/cjs/cat-alert_22.cjs.entry.js +351 -290
- package/dist/cjs/cat-alert_22.cjs.entry.js.map +1 -1
- package/dist/cjs/cat-icon-registry-2a54df3d.js +417 -0
- package/dist/cjs/cat-icon-registry-2a54df3d.js.map +1 -0
- package/dist/cjs/catalyst.cjs.js +1 -1
- package/dist/cjs/index.cjs.js +528 -4
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/cat-button/cat-button.css +21 -63
- package/dist/collection/components/cat-button/cat-button.js +21 -4
- package/dist/collection/components/cat-button/cat-button.js.map +1 -1
- package/dist/collection/components/cat-card/cat-card.css +5 -4
- package/dist/collection/components/cat-checkbox/cat-checkbox.css +1 -4
- package/dist/collection/components/cat-checkbox/cat-checkbox.js +1 -1
- package/dist/collection/components/cat-checkbox/cat-checkbox.js.map +1 -1
- package/dist/collection/components/{cat-menu/cat-menu.css → cat-dropdown/cat-dropdown.css} +20 -0
- package/dist/collection/components/{cat-menu/cat-menu.js → cat-dropdown/cat-dropdown.js} +102 -87
- package/dist/collection/components/cat-dropdown/cat-dropdown.js.map +1 -0
- package/dist/collection/components/cat-i18n/cat-i18n-registry.js +13 -38
- package/dist/collection/components/cat-i18n/cat-i18n-registry.js.map +1 -1
- package/dist/collection/components/cat-icon/cat-icon-registry.js +1 -0
- package/dist/collection/components/cat-icon/cat-icon-registry.js.map +1 -1
- package/dist/collection/components/cat-input/cat-input.css +1 -4
- package/dist/collection/components/cat-input/cat-input.js +4 -5
- package/dist/collection/components/cat-input/cat-input.js.map +1 -1
- package/dist/collection/components/cat-notification/cat-notification.js +61 -89
- package/dist/collection/components/cat-notification/cat-notification.js.map +1 -1
- package/dist/collection/components/cat-pagination/cat-pagination.css +106 -0
- package/dist/collection/components/cat-pagination/cat-pagination.js +302 -0
- package/dist/collection/components/cat-pagination/cat-pagination.js.map +1 -0
- package/dist/collection/components/cat-radio/cat-radio.css +1 -4
- package/dist/collection/components/cat-radio/cat-radio.js +1 -1
- package/dist/collection/components/cat-radio/cat-radio.js.map +1 -1
- package/dist/collection/components/cat-select/cat-select.css +1 -4
- package/dist/collection/components/cat-select/cat-select.js +8 -9
- package/dist/collection/components/cat-select/cat-select.js.map +1 -1
- package/dist/collection/components/cat-select-demo/cat-select-demo.js +1 -1
- package/dist/collection/components/cat-select-demo/cat-select-demo.js.map +1 -1
- package/dist/collection/components/cat-tabs/cat-tabs.css +2 -2
- package/dist/collection/components/cat-tabs/cat-tabs.js +2 -2
- package/dist/collection/components/cat-tabs/cat-tabs.js.map +1 -1
- package/dist/collection/components/cat-textarea/cat-textarea.css +1 -4
- package/dist/collection/components/cat-textarea/cat-textarea.js +1 -1
- package/dist/collection/components/cat-textarea/cat-textarea.js.map +1 -1
- package/dist/collection/components/cat-toggle/cat-toggle.css +1 -4
- package/dist/collection/components/cat-toggle/cat-toggle.js +1 -1
- package/dist/collection/components/cat-toggle/cat-toggle.js.map +1 -1
- package/dist/collection/index.cdn.js +10 -6
- package/dist/collection/index.js +3 -3
- package/dist/collection/index.js.map +1 -1
- package/dist/collection/scss/_variables.scss +1 -1
- package/dist/collection/scss/core/_form.scss +8 -0
- package/dist/collection/scss/core/_nav.scss +3 -3
- package/dist/collection/scss/core/_notification.scss +48 -0
- package/dist/collection/scss/index.scss +2 -1
- package/dist/collection/scss/utils/_typography.scss +4 -0
- package/dist/components/cat-button2.js +6 -5
- package/dist/components/cat-button2.js.map +1 -1
- package/dist/components/cat-card.js +1 -1
- package/dist/components/cat-card.js.map +1 -1
- package/dist/components/cat-checkbox2.js +2 -2
- package/dist/components/cat-checkbox2.js.map +1 -1
- package/dist/components/{cat-menu.d.ts → cat-dropdown.d.ts} +4 -4
- package/dist/components/cat-dropdown.js +8 -0
- package/dist/components/cat-dropdown.js.map +1 -0
- package/dist/components/cat-dropdown2.js +195 -0
- package/dist/components/cat-dropdown2.js.map +1 -0
- package/dist/components/cat-i18n-registry.js +14 -39
- package/dist/components/cat-i18n-registry.js.map +1 -1
- package/dist/components/cat-icon2.js +2 -1
- package/dist/components/cat-icon2.js.map +1 -1
- package/dist/components/cat-input.js +5 -6
- package/dist/components/cat-input.js.map +1 -1
- package/dist/components/{cat-toast-demo.d.ts → cat-pagination.d.ts} +4 -4
- package/dist/components/cat-pagination.js +150 -0
- package/dist/components/cat-pagination.js.map +1 -0
- package/dist/components/cat-radio.js +2 -2
- package/dist/components/cat-radio.js.map +1 -1
- package/dist/components/cat-select-demo.js +6 -6
- package/dist/components/cat-select-demo.js.map +1 -1
- package/dist/components/cat-select2.js +7 -8
- package/dist/components/cat-select2.js.map +1 -1
- package/dist/components/cat-tabs.js +3 -3
- package/dist/components/cat-tabs.js.map +1 -1
- package/dist/components/cat-textarea.js +2 -2
- package/dist/components/cat-textarea.js.map +1 -1
- package/dist/components/cat-toggle.js +2 -2
- package/dist/components/cat-toggle.js.map +1 -1
- package/dist/components/index.d.ts +2 -2
- package/dist/components/index.js +531 -4
- package/dist/components/index.js.map +1 -1
- package/dist/esm/cat-alert_22.entry.js +348 -287
- package/dist/esm/cat-alert_22.entry.js.map +1 -1
- package/dist/esm/cat-icon-registry-d537b18b.js +409 -0
- package/dist/esm/cat-icon-registry-d537b18b.js.map +1 -0
- package/dist/esm/catalyst.js +1 -1
- package/dist/esm/index.js +527 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/cat-button/cat-button.d.ts +4 -0
- package/dist/types/components/{cat-menu/cat-menu.d.ts → cat-dropdown/cat-dropdown.d.ts} +19 -12
- package/dist/types/components/cat-i18n/cat-i18n-registry.d.ts +4 -6
- package/dist/types/components/cat-icon/cat-icon-registry.d.ts +1 -0
- package/dist/types/components/cat-input/cat-input.d.ts +0 -1
- package/dist/types/components/cat-notification/cat-notification.d.ts +21 -48
- package/dist/types/components/cat-pagination/cat-pagination.d.ts +56 -0
- package/dist/types/components/cat-select/cat-select.d.ts +0 -1
- package/dist/types/components.d.ts +145 -57
- package/dist/types/index.d.ts +4 -4
- package/package.json +3 -3
- package/dist/catalyst/p-10b0d7a2.js +0 -10
- package/dist/catalyst/p-10b0d7a2.js.map +0 -1
- package/dist/catalyst/p-b561dcd4.entry.js +0 -2
- package/dist/catalyst/p-b561dcd4.entry.js.map +0 -1
- package/dist/catalyst/scss/core/_toast.scss +0 -87
- package/dist/cjs/cat-notification-bcb9fb86.js +0 -990
- package/dist/cjs/cat-notification-bcb9fb86.js.map +0 -1
- package/dist/collection/components/cat-menu/cat-menu.js.map +0 -1
- package/dist/collection/components/cat-toast-demo/cat-toast-demo.css +0 -3
- package/dist/collection/components/cat-toast-demo/cat-toast-demo.js +0 -62
- package/dist/collection/components/cat-toast-demo/cat-toast-demo.js.map +0 -1
- package/dist/collection/scss/core/_toast.scss +0 -87
- package/dist/components/cat-menu.js +0 -8
- package/dist/components/cat-menu.js.map +0 -1
- package/dist/components/cat-menu2.js +0 -176
- package/dist/components/cat-menu2.js.map +0 -1
- package/dist/components/cat-toast-demo.js +0 -647
- package/dist/components/cat-toast-demo.js.map +0 -1
- package/dist/esm/cat-notification-8bcf6fa2.js +0 -985
- package/dist/esm/cat-notification-8bcf6fa2.js.map +0 -1
- package/dist/types/components/cat-toast-demo/cat-toast-demo.d.ts +0 -9
|
@@ -1,36 +1,45 @@
|
|
|
1
1
|
import { Placement } from '@floating-ui/dom';
|
|
2
2
|
import { EventEmitter } from '../../stencil-public-runtime';
|
|
3
|
-
export declare class
|
|
3
|
+
export declare class CatDropdown {
|
|
4
4
|
private static readonly OFFSET;
|
|
5
5
|
private readonly id;
|
|
6
|
-
private triggerSlot
|
|
6
|
+
private triggerSlot;
|
|
7
7
|
private trigger?;
|
|
8
|
-
private content
|
|
8
|
+
private content;
|
|
9
9
|
private trap?;
|
|
10
10
|
private keyListener?;
|
|
11
|
+
private isOpen;
|
|
11
12
|
/**
|
|
12
|
-
* The placement of the
|
|
13
|
+
* The placement of the dropdown.
|
|
13
14
|
*/
|
|
14
15
|
placement: Placement;
|
|
15
16
|
/**
|
|
16
|
-
* Do not close the
|
|
17
|
+
* Do not close the dropdown on outside clicks.
|
|
17
18
|
*/
|
|
18
19
|
noAutoClose: boolean;
|
|
19
20
|
/**
|
|
20
|
-
* Allow overflow when
|
|
21
|
+
* Allow overflow when dropdown is open.
|
|
21
22
|
*/
|
|
22
23
|
overflow: boolean;
|
|
23
24
|
/**
|
|
24
|
-
* Emitted when the
|
|
25
|
+
* Emitted when the dropdown is opened.
|
|
25
26
|
*/
|
|
26
27
|
catOpen: EventEmitter<FocusEvent>;
|
|
27
28
|
/**
|
|
28
|
-
* Emitted when the
|
|
29
|
+
* Emitted when the dropdown is closed.
|
|
29
30
|
*/
|
|
30
31
|
catClose: EventEmitter<FocusEvent>;
|
|
31
32
|
clickHandler(event: CustomEvent<MouseEvent>): void;
|
|
32
33
|
/**
|
|
33
|
-
*
|
|
34
|
+
* Toggles the dropdown.
|
|
35
|
+
*/
|
|
36
|
+
toggle(): Promise<void>;
|
|
37
|
+
/**
|
|
38
|
+
* Opens the dropdown.
|
|
39
|
+
*/
|
|
40
|
+
open(): Promise<void>;
|
|
41
|
+
/**
|
|
42
|
+
* Closes the dropdown.
|
|
34
43
|
*/
|
|
35
44
|
close(): Promise<void>;
|
|
36
45
|
componentDidLoad(): void;
|
|
@@ -38,8 +47,6 @@ export declare class CatMenu {
|
|
|
38
47
|
render(): any;
|
|
39
48
|
private get contentId();
|
|
40
49
|
private initTrigger;
|
|
41
|
-
private show;
|
|
42
|
-
private hide;
|
|
43
|
-
private update;
|
|
44
50
|
private findTrigger;
|
|
51
|
+
private update;
|
|
45
52
|
}
|
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
export declare class CatI18nRegistry {
|
|
2
2
|
private static instance;
|
|
3
|
-
private
|
|
4
|
-
private readonly _dicts;
|
|
3
|
+
private readonly i18n;
|
|
5
4
|
private constructor();
|
|
6
5
|
static getInstance(): CatI18nRegistry;
|
|
7
|
-
|
|
8
|
-
register(locale: string, i18n: {
|
|
6
|
+
set(i18n: {
|
|
9
7
|
[key: string]: string;
|
|
10
8
|
}): void;
|
|
11
|
-
clear(
|
|
9
|
+
clear(): void;
|
|
12
10
|
t(key: string, params?: {
|
|
13
11
|
[key: string]: string | number;
|
|
14
12
|
}): string;
|
|
15
13
|
private buildEvent;
|
|
16
|
-
private getDict;
|
|
17
14
|
}
|
|
15
|
+
export declare const catI18nRegistry: CatI18nRegistry;
|
|
@@ -1,56 +1,29 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
'primary' = "star-circle-filled",
|
|
6
|
-
'secondary' = "info-circle-filled"
|
|
7
|
-
}
|
|
8
|
-
export declare const ToastPositions: {
|
|
9
|
-
[key: string]: {
|
|
10
|
-
gravity: 'top' | 'bottom';
|
|
11
|
-
position: 'left' | 'center' | 'right';
|
|
1
|
+
interface ToastRef {
|
|
2
|
+
toast?: {
|
|
3
|
+
showToast: () => void;
|
|
4
|
+
hideToast: () => void;
|
|
12
5
|
};
|
|
13
|
-
};
|
|
14
|
-
export interface ToastPosition {
|
|
15
|
-
gravity: 'top' | 'bottom';
|
|
16
|
-
position: 'left' | 'center' | 'right';
|
|
17
6
|
}
|
|
18
7
|
export interface ToastOptions {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
*/
|
|
22
|
-
content: Node;
|
|
23
|
-
/**
|
|
24
|
-
* Show close button
|
|
25
|
-
*/
|
|
26
|
-
close: boolean;
|
|
27
|
-
/**
|
|
28
|
-
* Toast position
|
|
29
|
-
*/
|
|
8
|
+
mode: 'dark' | 'light';
|
|
9
|
+
icon: string;
|
|
30
10
|
position: 'top-left' | 'top-center' | 'top-right' | 'bottom-left' | 'bottom-center' | 'bottom-right';
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
type: 'success' | 'info' | 'error' | 'primary' | 'secondary';
|
|
35
|
-
/**
|
|
36
|
-
* Invoked when the toast is clicked
|
|
37
|
-
*/
|
|
38
|
-
onClick: () => void;
|
|
39
|
-
/**
|
|
40
|
-
* Toggle the default behavior of escaping HTML markup
|
|
41
|
-
*/
|
|
11
|
+
autoClose: boolean;
|
|
12
|
+
duration: number;
|
|
13
|
+
action: string;
|
|
42
14
|
escapeMarkup: boolean;
|
|
15
|
+
onAction: (toast: ToastRef) => void;
|
|
16
|
+
onClick: (toast: ToastRef) => void;
|
|
17
|
+
onDismiss: (toast: ToastRef) => void;
|
|
43
18
|
}
|
|
44
|
-
declare class CatNotificationService {
|
|
45
|
-
private static
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
private
|
|
52
|
-
private getPosition;
|
|
53
|
-
private extractOptions;
|
|
19
|
+
export declare class CatNotificationService {
|
|
20
|
+
private static instance;
|
|
21
|
+
private static duration;
|
|
22
|
+
private constructor();
|
|
23
|
+
static getInstance(): CatNotificationService;
|
|
24
|
+
show(content: string | Node, options?: Partial<ToastOptions>): () => void;
|
|
25
|
+
private getNode;
|
|
26
|
+
private getOptions;
|
|
54
27
|
}
|
|
55
|
-
export declare const
|
|
28
|
+
export declare const catNotificationService: CatNotificationService;
|
|
56
29
|
export {};
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A navigation component to switch between different pages of paged chunks of
|
|
3
|
+
* data such as a table. Pagination is built with list HTML elements and a
|
|
4
|
+
* wrapping `<nav>` element to identify it as a navigation section to screen
|
|
5
|
+
* readers and other assistive technologies. Furthermore, the current page is
|
|
6
|
+
* correctly highlighted using `aria-current`.
|
|
7
|
+
*/
|
|
8
|
+
export declare class CatPagination {
|
|
9
|
+
/**
|
|
10
|
+
* The current page.
|
|
11
|
+
*/
|
|
12
|
+
page: number;
|
|
13
|
+
/**
|
|
14
|
+
* The total number of pages.
|
|
15
|
+
*/
|
|
16
|
+
pageCount: number;
|
|
17
|
+
/**
|
|
18
|
+
* The number of pages to be shown around the current page.
|
|
19
|
+
*/
|
|
20
|
+
activePadding: number;
|
|
21
|
+
/**
|
|
22
|
+
* The number of pages to be shown at the edges.
|
|
23
|
+
*/
|
|
24
|
+
sidePadding: number;
|
|
25
|
+
/**
|
|
26
|
+
* The size of the buttons.
|
|
27
|
+
*/
|
|
28
|
+
size: 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
29
|
+
/**
|
|
30
|
+
* The rendering style of the buttons.
|
|
31
|
+
*/
|
|
32
|
+
variant: 'filled' | 'outlined' | 'text';
|
|
33
|
+
/**
|
|
34
|
+
* Use round button edges.
|
|
35
|
+
*/
|
|
36
|
+
round: boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Use compact pagination mode.
|
|
39
|
+
*/
|
|
40
|
+
compact: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* The icon of the "previous" button.
|
|
43
|
+
*/
|
|
44
|
+
iconPrev: string;
|
|
45
|
+
/**
|
|
46
|
+
* The icon of the "next" button.
|
|
47
|
+
*/
|
|
48
|
+
iconNext: string;
|
|
49
|
+
render(): any;
|
|
50
|
+
get isFirst(): boolean;
|
|
51
|
+
get isLast(): boolean;
|
|
52
|
+
get pages(): number[];
|
|
53
|
+
private addSeq;
|
|
54
|
+
private clamp;
|
|
55
|
+
private get content();
|
|
56
|
+
}
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
|
|
8
8
|
import { Breakpoint } from "./utils/breakpoints";
|
|
9
|
-
import { InputType } from "./components/cat-input/input-type";
|
|
10
9
|
import { Placement } from "@floating-ui/dom";
|
|
10
|
+
import { InputType } from "./components/cat-input/input-type";
|
|
11
11
|
import { CatSelectConnector, CatSelectMultipleTaggingValue, CatSelectTaggingValue, Item } from "./components/cat-select/cat-select";
|
|
12
12
|
import { Observable } from "rxjs";
|
|
13
13
|
export namespace Components {
|
|
@@ -82,6 +82,10 @@ export namespace Components {
|
|
|
82
82
|
"variant": 'filled' | 'outlined';
|
|
83
83
|
}
|
|
84
84
|
interface CatButton {
|
|
85
|
+
/**
|
|
86
|
+
* Sets the `aria-current` attribute on the button.
|
|
87
|
+
*/
|
|
88
|
+
"a11yCurrent"?: boolean;
|
|
85
89
|
/**
|
|
86
90
|
* Adds accessible label for the button that is only shown for screen readers. Typically, this label text replaces the visible text on the button for users who use assistive technology.
|
|
87
91
|
*/
|
|
@@ -209,6 +213,24 @@ export namespace Components {
|
|
|
209
213
|
*/
|
|
210
214
|
"value"?: string | boolean;
|
|
211
215
|
}
|
|
216
|
+
interface CatDropdown {
|
|
217
|
+
/**
|
|
218
|
+
* Closes the dropdown.
|
|
219
|
+
*/
|
|
220
|
+
"close": () => Promise<void>;
|
|
221
|
+
/**
|
|
222
|
+
* Do not close the dropdown on outside clicks.
|
|
223
|
+
*/
|
|
224
|
+
"noAutoClose": boolean;
|
|
225
|
+
/**
|
|
226
|
+
* Allow overflow when dropdown is open.
|
|
227
|
+
*/
|
|
228
|
+
"overflow": boolean;
|
|
229
|
+
/**
|
|
230
|
+
* The placement of the dropdown.
|
|
231
|
+
*/
|
|
232
|
+
"placement": Placement;
|
|
233
|
+
}
|
|
212
234
|
interface CatIcon {
|
|
213
235
|
/**
|
|
214
236
|
* Adds accessible label for the icon that is only shown for screen readers. The `aria-hidden` attribute will be set if no label is present.
|
|
@@ -318,33 +340,57 @@ export namespace Components {
|
|
|
318
340
|
*/
|
|
319
341
|
"value"?: string | number;
|
|
320
342
|
}
|
|
321
|
-
interface
|
|
343
|
+
interface CatModal {
|
|
322
344
|
/**
|
|
323
|
-
*
|
|
345
|
+
* Shows the modal.
|
|
324
346
|
*/
|
|
325
|
-
"
|
|
347
|
+
"show": () => Promise<void>;
|
|
326
348
|
/**
|
|
327
|
-
*
|
|
349
|
+
* The size of the modal.
|
|
328
350
|
*/
|
|
329
|
-
"
|
|
351
|
+
"size": 's' | 'm' | 'l';
|
|
352
|
+
}
|
|
353
|
+
interface CatPagination {
|
|
330
354
|
/**
|
|
331
|
-
*
|
|
355
|
+
* The number of pages to be shown around the current page.
|
|
332
356
|
*/
|
|
333
|
-
"
|
|
357
|
+
"activePadding": number;
|
|
334
358
|
/**
|
|
335
|
-
*
|
|
359
|
+
* Use compact pagination mode.
|
|
336
360
|
*/
|
|
337
|
-
"
|
|
338
|
-
}
|
|
339
|
-
interface CatModal {
|
|
361
|
+
"compact": boolean;
|
|
340
362
|
/**
|
|
341
|
-
*
|
|
363
|
+
* The icon of the "next" button.
|
|
342
364
|
*/
|
|
343
|
-
"
|
|
365
|
+
"iconNext": string;
|
|
344
366
|
/**
|
|
345
|
-
* The
|
|
367
|
+
* The icon of the "previous" button.
|
|
346
368
|
*/
|
|
347
|
-
"
|
|
369
|
+
"iconPrev": string;
|
|
370
|
+
/**
|
|
371
|
+
* The current page.
|
|
372
|
+
*/
|
|
373
|
+
"page": number;
|
|
374
|
+
/**
|
|
375
|
+
* The total number of pages.
|
|
376
|
+
*/
|
|
377
|
+
"pageCount": number;
|
|
378
|
+
/**
|
|
379
|
+
* Use round button edges.
|
|
380
|
+
*/
|
|
381
|
+
"round": boolean;
|
|
382
|
+
/**
|
|
383
|
+
* The number of pages to be shown at the edges.
|
|
384
|
+
*/
|
|
385
|
+
"sidePadding": number;
|
|
386
|
+
/**
|
|
387
|
+
* The size of the buttons.
|
|
388
|
+
*/
|
|
389
|
+
"size": 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
390
|
+
/**
|
|
391
|
+
* The rendering style of the buttons.
|
|
392
|
+
*/
|
|
393
|
+
"variant": 'filled' | 'outlined' | 'text';
|
|
348
394
|
}
|
|
349
395
|
interface CatRadio {
|
|
350
396
|
/**
|
|
@@ -629,8 +675,6 @@ export namespace Components {
|
|
|
629
675
|
*/
|
|
630
676
|
"value"?: string | number;
|
|
631
677
|
}
|
|
632
|
-
interface CatToastDemo {
|
|
633
|
-
}
|
|
634
678
|
interface CatToggle {
|
|
635
679
|
/**
|
|
636
680
|
* Checked state of the toggle.
|
|
@@ -717,13 +761,13 @@ export interface CatCheckboxCustomEvent<T> extends CustomEvent<T> {
|
|
|
717
761
|
detail: T;
|
|
718
762
|
target: HTMLCatCheckboxElement;
|
|
719
763
|
}
|
|
720
|
-
export interface
|
|
764
|
+
export interface CatDropdownCustomEvent<T> extends CustomEvent<T> {
|
|
721
765
|
detail: T;
|
|
722
|
-
target:
|
|
766
|
+
target: HTMLCatDropdownElement;
|
|
723
767
|
}
|
|
724
|
-
export interface
|
|
768
|
+
export interface CatInputCustomEvent<T> extends CustomEvent<T> {
|
|
725
769
|
detail: T;
|
|
726
|
-
target:
|
|
770
|
+
target: HTMLCatInputElement;
|
|
727
771
|
}
|
|
728
772
|
export interface CatRadioCustomEvent<T> extends CustomEvent<T> {
|
|
729
773
|
detail: T;
|
|
@@ -790,6 +834,12 @@ declare global {
|
|
|
790
834
|
prototype: HTMLCatCheckboxElement;
|
|
791
835
|
new (): HTMLCatCheckboxElement;
|
|
792
836
|
};
|
|
837
|
+
interface HTMLCatDropdownElement extends Components.CatDropdown, HTMLStencilElement {
|
|
838
|
+
}
|
|
839
|
+
var HTMLCatDropdownElement: {
|
|
840
|
+
prototype: HTMLCatDropdownElement;
|
|
841
|
+
new (): HTMLCatDropdownElement;
|
|
842
|
+
};
|
|
793
843
|
interface HTMLCatIconElement extends Components.CatIcon, HTMLStencilElement {
|
|
794
844
|
}
|
|
795
845
|
var HTMLCatIconElement: {
|
|
@@ -802,18 +852,18 @@ declare global {
|
|
|
802
852
|
prototype: HTMLCatInputElement;
|
|
803
853
|
new (): HTMLCatInputElement;
|
|
804
854
|
};
|
|
805
|
-
interface HTMLCatMenuElement extends Components.CatMenu, HTMLStencilElement {
|
|
806
|
-
}
|
|
807
|
-
var HTMLCatMenuElement: {
|
|
808
|
-
prototype: HTMLCatMenuElement;
|
|
809
|
-
new (): HTMLCatMenuElement;
|
|
810
|
-
};
|
|
811
855
|
interface HTMLCatModalElement extends Components.CatModal, HTMLStencilElement {
|
|
812
856
|
}
|
|
813
857
|
var HTMLCatModalElement: {
|
|
814
858
|
prototype: HTMLCatModalElement;
|
|
815
859
|
new (): HTMLCatModalElement;
|
|
816
860
|
};
|
|
861
|
+
interface HTMLCatPaginationElement extends Components.CatPagination, HTMLStencilElement {
|
|
862
|
+
}
|
|
863
|
+
var HTMLCatPaginationElement: {
|
|
864
|
+
prototype: HTMLCatPaginationElement;
|
|
865
|
+
new (): HTMLCatPaginationElement;
|
|
866
|
+
};
|
|
817
867
|
interface HTMLCatRadioElement extends Components.CatRadio, HTMLStencilElement {
|
|
818
868
|
}
|
|
819
869
|
var HTMLCatRadioElement: {
|
|
@@ -874,12 +924,6 @@ declare global {
|
|
|
874
924
|
prototype: HTMLCatTextareaElement;
|
|
875
925
|
new (): HTMLCatTextareaElement;
|
|
876
926
|
};
|
|
877
|
-
interface HTMLCatToastDemoElement extends Components.CatToastDemo, HTMLStencilElement {
|
|
878
|
-
}
|
|
879
|
-
var HTMLCatToastDemoElement: {
|
|
880
|
-
prototype: HTMLCatToastDemoElement;
|
|
881
|
-
new (): HTMLCatToastDemoElement;
|
|
882
|
-
};
|
|
883
927
|
interface HTMLCatToggleElement extends Components.CatToggle, HTMLStencilElement {
|
|
884
928
|
}
|
|
885
929
|
var HTMLCatToggleElement: {
|
|
@@ -899,10 +943,11 @@ declare global {
|
|
|
899
943
|
"cat-button": HTMLCatButtonElement;
|
|
900
944
|
"cat-card": HTMLCatCardElement;
|
|
901
945
|
"cat-checkbox": HTMLCatCheckboxElement;
|
|
946
|
+
"cat-dropdown": HTMLCatDropdownElement;
|
|
902
947
|
"cat-icon": HTMLCatIconElement;
|
|
903
948
|
"cat-input": HTMLCatInputElement;
|
|
904
|
-
"cat-menu": HTMLCatMenuElement;
|
|
905
949
|
"cat-modal": HTMLCatModalElement;
|
|
950
|
+
"cat-pagination": HTMLCatPaginationElement;
|
|
906
951
|
"cat-radio": HTMLCatRadioElement;
|
|
907
952
|
"cat-radio-group": HTMLCatRadioGroupElement;
|
|
908
953
|
"cat-scrollable": HTMLCatScrollableElement;
|
|
@@ -913,7 +958,6 @@ declare global {
|
|
|
913
958
|
"cat-tab": HTMLCatTabElement;
|
|
914
959
|
"cat-tabs": HTMLCatTabsElement;
|
|
915
960
|
"cat-textarea": HTMLCatTextareaElement;
|
|
916
|
-
"cat-toast-demo": HTMLCatToastDemoElement;
|
|
917
961
|
"cat-toggle": HTMLCatToggleElement;
|
|
918
962
|
"cat-tooltip": HTMLCatTooltipElement;
|
|
919
963
|
}
|
|
@@ -990,6 +1034,10 @@ declare namespace LocalJSX {
|
|
|
990
1034
|
"variant"?: 'filled' | 'outlined';
|
|
991
1035
|
}
|
|
992
1036
|
interface CatButton {
|
|
1037
|
+
/**
|
|
1038
|
+
* Sets the `aria-current` attribute on the button.
|
|
1039
|
+
*/
|
|
1040
|
+
"a11yCurrent"?: boolean;
|
|
993
1041
|
/**
|
|
994
1042
|
* Adds accessible label for the button that is only shown for screen readers. Typically, this label text replaces the visible text on the button for users who use assistive technology.
|
|
995
1043
|
*/
|
|
@@ -1131,6 +1179,28 @@ declare namespace LocalJSX {
|
|
|
1131
1179
|
*/
|
|
1132
1180
|
"value"?: string | boolean;
|
|
1133
1181
|
}
|
|
1182
|
+
interface CatDropdown {
|
|
1183
|
+
/**
|
|
1184
|
+
* Do not close the dropdown on outside clicks.
|
|
1185
|
+
*/
|
|
1186
|
+
"noAutoClose"?: boolean;
|
|
1187
|
+
/**
|
|
1188
|
+
* Emitted when the dropdown is closed.
|
|
1189
|
+
*/
|
|
1190
|
+
"onCatClose"?: (event: CatDropdownCustomEvent<FocusEvent>) => void;
|
|
1191
|
+
/**
|
|
1192
|
+
* Emitted when the dropdown is opened.
|
|
1193
|
+
*/
|
|
1194
|
+
"onCatOpen"?: (event: CatDropdownCustomEvent<FocusEvent>) => void;
|
|
1195
|
+
/**
|
|
1196
|
+
* Allow overflow when dropdown is open.
|
|
1197
|
+
*/
|
|
1198
|
+
"overflow"?: boolean;
|
|
1199
|
+
/**
|
|
1200
|
+
* The placement of the dropdown.
|
|
1201
|
+
*/
|
|
1202
|
+
"placement"?: Placement;
|
|
1203
|
+
}
|
|
1134
1204
|
interface CatIcon {
|
|
1135
1205
|
/**
|
|
1136
1206
|
* Adds accessible label for the icon that is only shown for screen readers. The `aria-hidden` attribute will be set if no label is present.
|
|
@@ -1243,33 +1313,53 @@ declare namespace LocalJSX {
|
|
|
1243
1313
|
*/
|
|
1244
1314
|
"value"?: string | number;
|
|
1245
1315
|
}
|
|
1246
|
-
interface
|
|
1316
|
+
interface CatModal {
|
|
1247
1317
|
/**
|
|
1248
|
-
*
|
|
1318
|
+
* The size of the modal.
|
|
1249
1319
|
*/
|
|
1250
|
-
"
|
|
1320
|
+
"size"?: 's' | 'm' | 'l';
|
|
1321
|
+
}
|
|
1322
|
+
interface CatPagination {
|
|
1251
1323
|
/**
|
|
1252
|
-
*
|
|
1324
|
+
* The number of pages to be shown around the current page.
|
|
1253
1325
|
*/
|
|
1254
|
-
"
|
|
1326
|
+
"activePadding"?: number;
|
|
1255
1327
|
/**
|
|
1256
|
-
*
|
|
1328
|
+
* Use compact pagination mode.
|
|
1257
1329
|
*/
|
|
1258
|
-
"
|
|
1330
|
+
"compact"?: boolean;
|
|
1259
1331
|
/**
|
|
1260
|
-
*
|
|
1332
|
+
* The icon of the "next" button.
|
|
1261
1333
|
*/
|
|
1262
|
-
"
|
|
1334
|
+
"iconNext"?: string;
|
|
1263
1335
|
/**
|
|
1264
|
-
* The
|
|
1336
|
+
* The icon of the "previous" button.
|
|
1265
1337
|
*/
|
|
1266
|
-
"
|
|
1267
|
-
}
|
|
1268
|
-
interface CatModal {
|
|
1338
|
+
"iconPrev"?: string;
|
|
1269
1339
|
/**
|
|
1270
|
-
* The
|
|
1340
|
+
* The current page.
|
|
1271
1341
|
*/
|
|
1272
|
-
"
|
|
1342
|
+
"page"?: number;
|
|
1343
|
+
/**
|
|
1344
|
+
* The total number of pages.
|
|
1345
|
+
*/
|
|
1346
|
+
"pageCount"?: number;
|
|
1347
|
+
/**
|
|
1348
|
+
* Use round button edges.
|
|
1349
|
+
*/
|
|
1350
|
+
"round"?: boolean;
|
|
1351
|
+
/**
|
|
1352
|
+
* The number of pages to be shown at the edges.
|
|
1353
|
+
*/
|
|
1354
|
+
"sidePadding"?: number;
|
|
1355
|
+
/**
|
|
1356
|
+
* The size of the buttons.
|
|
1357
|
+
*/
|
|
1358
|
+
"size"?: 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
1359
|
+
/**
|
|
1360
|
+
* The rendering style of the buttons.
|
|
1361
|
+
*/
|
|
1362
|
+
"variant"?: 'filled' | 'outlined' | 'text';
|
|
1273
1363
|
}
|
|
1274
1364
|
interface CatRadio {
|
|
1275
1365
|
/**
|
|
@@ -1607,8 +1697,6 @@ declare namespace LocalJSX {
|
|
|
1607
1697
|
*/
|
|
1608
1698
|
"value"?: string | number;
|
|
1609
1699
|
}
|
|
1610
|
-
interface CatToastDemo {
|
|
1611
|
-
}
|
|
1612
1700
|
interface CatToggle {
|
|
1613
1701
|
/**
|
|
1614
1702
|
* Checked state of the toggle.
|
|
@@ -1700,10 +1788,11 @@ declare namespace LocalJSX {
|
|
|
1700
1788
|
"cat-button": CatButton;
|
|
1701
1789
|
"cat-card": CatCard;
|
|
1702
1790
|
"cat-checkbox": CatCheckbox;
|
|
1791
|
+
"cat-dropdown": CatDropdown;
|
|
1703
1792
|
"cat-icon": CatIcon;
|
|
1704
1793
|
"cat-input": CatInput;
|
|
1705
|
-
"cat-menu": CatMenu;
|
|
1706
1794
|
"cat-modal": CatModal;
|
|
1795
|
+
"cat-pagination": CatPagination;
|
|
1707
1796
|
"cat-radio": CatRadio;
|
|
1708
1797
|
"cat-radio-group": CatRadioGroup;
|
|
1709
1798
|
"cat-scrollable": CatScrollable;
|
|
@@ -1714,7 +1803,6 @@ declare namespace LocalJSX {
|
|
|
1714
1803
|
"cat-tab": CatTab;
|
|
1715
1804
|
"cat-tabs": CatTabs;
|
|
1716
1805
|
"cat-textarea": CatTextarea;
|
|
1717
|
-
"cat-toast-demo": CatToastDemo;
|
|
1718
1806
|
"cat-toggle": CatToggle;
|
|
1719
1807
|
"cat-tooltip": CatTooltip;
|
|
1720
1808
|
}
|
|
@@ -1729,10 +1817,11 @@ declare module "@stencil/core" {
|
|
|
1729
1817
|
"cat-button": LocalJSX.CatButton & JSXBase.HTMLAttributes<HTMLCatButtonElement>;
|
|
1730
1818
|
"cat-card": LocalJSX.CatCard & JSXBase.HTMLAttributes<HTMLCatCardElement>;
|
|
1731
1819
|
"cat-checkbox": LocalJSX.CatCheckbox & JSXBase.HTMLAttributes<HTMLCatCheckboxElement>;
|
|
1820
|
+
"cat-dropdown": LocalJSX.CatDropdown & JSXBase.HTMLAttributes<HTMLCatDropdownElement>;
|
|
1732
1821
|
"cat-icon": LocalJSX.CatIcon & JSXBase.HTMLAttributes<HTMLCatIconElement>;
|
|
1733
1822
|
"cat-input": LocalJSX.CatInput & JSXBase.HTMLAttributes<HTMLCatInputElement>;
|
|
1734
|
-
"cat-menu": LocalJSX.CatMenu & JSXBase.HTMLAttributes<HTMLCatMenuElement>;
|
|
1735
1823
|
"cat-modal": LocalJSX.CatModal & JSXBase.HTMLAttributes<HTMLCatModalElement>;
|
|
1824
|
+
"cat-pagination": LocalJSX.CatPagination & JSXBase.HTMLAttributes<HTMLCatPaginationElement>;
|
|
1736
1825
|
"cat-radio": LocalJSX.CatRadio & JSXBase.HTMLAttributes<HTMLCatRadioElement>;
|
|
1737
1826
|
"cat-radio-group": LocalJSX.CatRadioGroup & JSXBase.HTMLAttributes<HTMLCatRadioGroupElement>;
|
|
1738
1827
|
"cat-scrollable": LocalJSX.CatScrollable & JSXBase.HTMLAttributes<HTMLCatScrollableElement>;
|
|
@@ -1743,7 +1832,6 @@ declare module "@stencil/core" {
|
|
|
1743
1832
|
"cat-tab": LocalJSX.CatTab & JSXBase.HTMLAttributes<HTMLCatTabElement>;
|
|
1744
1833
|
"cat-tabs": LocalJSX.CatTabs & JSXBase.HTMLAttributes<HTMLCatTabsElement>;
|
|
1745
1834
|
"cat-textarea": LocalJSX.CatTextarea & JSXBase.HTMLAttributes<HTMLCatTextareaElement>;
|
|
1746
|
-
"cat-toast-demo": LocalJSX.CatToastDemo & JSXBase.HTMLAttributes<HTMLCatToastDemoElement>;
|
|
1747
1835
|
"cat-toggle": LocalJSX.CatToggle & JSXBase.HTMLAttributes<HTMLCatToggleElement>;
|
|
1748
1836
|
"cat-tooltip": LocalJSX.CatTooltip & JSXBase.HTMLAttributes<HTMLCatTooltipElement>;
|
|
1749
1837
|
}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { Components, JSX } from './components';
|
|
2
|
-
export { CatI18nRegistry } from './components/cat-i18n/cat-i18n-registry';
|
|
3
|
-
export { CatIconRegistry } from './components/cat-icon/cat-icon-registry';
|
|
4
|
-
export {
|
|
5
|
-
export {
|
|
2
|
+
export { catI18nRegistry, CatI18nRegistry } from './components/cat-i18n/cat-i18n-registry';
|
|
3
|
+
export { catIconRegistry, CatIconRegistry } from './components/cat-icon/cat-icon-registry';
|
|
4
|
+
export { catNotificationService, CatNotificationService, ToastOptions } from './components/cat-notification/cat-notification';
|
|
5
|
+
export { CatSelectConnector, CatSelectMultipleTaggingValue, CatSelectTaggingValue, Item, Page, RenderInfo } from './components/cat-select/cat-select';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@haiilo/catalyst",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.1",
|
|
4
4
|
"description": "Catalyst Design System",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
"dependencies": {
|
|
47
47
|
"@floating-ui/dom": "1.0.3",
|
|
48
|
-
"@haiilo/catalyst-tokens": "
|
|
48
|
+
"@haiilo/catalyst-tokens": "2.0.1",
|
|
49
49
|
"@stencil/core": "2.17.4",
|
|
50
50
|
"autosize": "5.0.1",
|
|
51
51
|
"autosize-input": "1.0.2",
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"rxjs": "^7.5.5",
|
|
78
78
|
"stylelint": "^14.14.0",
|
|
79
79
|
"stylelint-config-prettier-scss": "^0.0.1",
|
|
80
|
-
"stylelint-config-standard-scss": "^
|
|
80
|
+
"stylelint-config-standard-scss": "^6.0.0",
|
|
81
81
|
"typescript": "^4.5.5"
|
|
82
82
|
}
|
|
83
83
|
}
|