@kubex/zinc 1.0.6 → 1.0.8
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/custom-elements.json +464 -34
- package/dist/vscode.html-custom-data.json +38 -6
- package/dist/web-types.json +97 -10
- package/dist/zn.d.ts +73 -8
- package/dist/zn.min.js +393 -349
- package/docs/data/products-table.json +203 -0
- package/docs/pages/components/button.md +25 -0
- package/docs/pages/components/data-table.md +21 -0
- package/docs/pages/components/header.md +7 -0
- package/docs/pages/components/order-table.md +82 -5
- package/package.json +1 -1
- package/src/components/button/button.component.ts +168 -10
- package/src/components/button/button.scss +115 -0
- package/src/components/content-block/content-block.component.ts +186 -107
- package/src/components/content-block/content-block.scss +4 -2
- package/src/components/data-select/data-select.component.ts +50 -10
- package/src/components/data-table/data-table.component.ts +130 -43
- package/src/components/data-table/data-table.scss +85 -7
- package/src/components/data-table-filter/data-table-filter.component.ts +1 -1
- package/src/components/editor/editor.scss +1 -0
- package/src/components/editor/modules/attachment/attachment.ts +53 -41
- package/src/components/editor/modules/toolbar/toolbar.ts +42 -0
- package/src/components/empty-state/empty-state.component.ts +16 -8
- package/src/components/expanding-action/expanding-action.component.ts +1 -1
- package/src/components/header/header.component.ts +8 -2
- package/src/components/header/header.scss +5 -1
- package/src/components/icon/icon.component.ts +2 -0
- package/src/components/icon/icon.scss +13 -0
- package/src/components/item/item.component.ts +11 -3
- package/src/components/item/item.scss +7 -4
- package/src/components/linked-select/linked-select.component.ts +1 -0
- package/src/components/menu/menu.component.ts +0 -1
- package/src/components/navbar/navbar.component.ts +1 -1
- package/src/components/note/note.component.ts +70 -2
- package/src/components/note/note.scss +26 -4
- package/src/components/order-table/order-table.component.ts +49 -28
- package/src/components/panel/panel.component.ts +5 -1
- package/src/components/panel/panel.scss +6 -0
- package/src/components/rating/rating.component.ts +10 -9
- package/src/components/rating/rating.scss +15 -1
package/dist/zn.d.ts
CHANGED
|
@@ -504,6 +504,7 @@ declare module "components/icon/icon.component" {
|
|
|
504
504
|
library: IconLibrary;
|
|
505
505
|
color: IconColor;
|
|
506
506
|
padded: boolean;
|
|
507
|
+
blink: boolean;
|
|
507
508
|
squared: boolean;
|
|
508
509
|
gravatarOptions: string;
|
|
509
510
|
defaultLibrary: IconLibrary;
|
|
@@ -1057,6 +1058,7 @@ declare module "components/button/button.component" {
|
|
|
1057
1058
|
* @slot - The button's label.
|
|
1058
1059
|
* @slot prefix - A presentational prefix icon or similar element.
|
|
1059
1060
|
* @slot suffix - A presentational suffix icon or similar element.
|
|
1061
|
+
* @slot cancel - Slot for custom cancel button/content when autoClick is active.
|
|
1060
1062
|
*
|
|
1061
1063
|
* @csspart base - The component's base wrapper.
|
|
1062
1064
|
* @csspart prefix - The container that wraps the prefix.
|
|
@@ -1073,7 +1075,10 @@ declare module "components/button/button.component" {
|
|
|
1073
1075
|
};
|
|
1074
1076
|
private readonly formControlController;
|
|
1075
1077
|
private readonly hasSlotController;
|
|
1078
|
+
private _autoClickTimeout;
|
|
1079
|
+
private _loadingState;
|
|
1076
1080
|
button: HTMLButtonElement;
|
|
1081
|
+
countdownContainer: HTMLElement[];
|
|
1077
1082
|
color: 'default' | 'secondary' | 'error' | 'info' | 'success' | 'warning' | 'transparent' | 'star';
|
|
1078
1083
|
size: 'content' | 'x-small' | 'small' | 'medium' | 'large';
|
|
1079
1084
|
text: boolean;
|
|
@@ -1105,9 +1110,16 @@ declare module "components/button/button.component" {
|
|
|
1105
1110
|
dataTarget: 'modal' | 'slide' | string;
|
|
1106
1111
|
rel: string;
|
|
1107
1112
|
tooltip: string;
|
|
1113
|
+
autoClick: boolean;
|
|
1114
|
+
autoClickDelay: number;
|
|
1115
|
+
loadingText: string;
|
|
1116
|
+
loadingTextPosition: 'left' | 'right' | 'center' | string;
|
|
1117
|
+
loading: boolean;
|
|
1108
1118
|
get validity(): ValidityState;
|
|
1109
1119
|
get validationMessage(): string;
|
|
1110
1120
|
firstUpdated(): void;
|
|
1121
|
+
disconnectedCallback(): void;
|
|
1122
|
+
protected updated(changedProps: Map<string, any>): void;
|
|
1111
1123
|
checkValidity(): boolean;
|
|
1112
1124
|
getForm(): HTMLFormElement | null;
|
|
1113
1125
|
reportValidity(): boolean;
|
|
@@ -1115,6 +1127,9 @@ declare module "components/button/button.component" {
|
|
|
1115
1127
|
handleClick: () => void;
|
|
1116
1128
|
private _isLink;
|
|
1117
1129
|
private _isButton;
|
|
1130
|
+
setupAutoClick(): void;
|
|
1131
|
+
updateCountdownText(): void;
|
|
1132
|
+
teardownAutoClick(): void;
|
|
1118
1133
|
protected render(): unknown;
|
|
1119
1134
|
}
|
|
1120
1135
|
}
|
|
@@ -1518,6 +1533,7 @@ declare module "components/empty-state/empty-state.component" {
|
|
|
1518
1533
|
description: string;
|
|
1519
1534
|
type: 'error' | 'info' | 'primary' | '';
|
|
1520
1535
|
padded: boolean;
|
|
1536
|
+
private readonly hasSlotController;
|
|
1521
1537
|
render(): import("lit").TemplateResult<1>;
|
|
1522
1538
|
}
|
|
1523
1539
|
}
|
|
@@ -2032,10 +2048,10 @@ declare module "components/select/index" {
|
|
|
2032
2048
|
}
|
|
2033
2049
|
declare module "components/data-select/data-select.component" {
|
|
2034
2050
|
import { type DataProviderOption, type LocalDataProvider } from "components/data-select/providers/provider";
|
|
2051
|
+
import { type CSSResultGroup, PropertyValues } from 'lit';
|
|
2035
2052
|
import { FormControlController } from "internal/form";
|
|
2036
|
-
import ZincElement from "internal/zinc-element";
|
|
2037
|
-
import type { CSSResultGroup } from 'lit';
|
|
2038
2053
|
import type { ZincFormControl } from "internal/zinc-element";
|
|
2054
|
+
import ZincElement from "internal/zinc-element";
|
|
2039
2055
|
import type ZnSelect from "components/select/index";
|
|
2040
2056
|
/**
|
|
2041
2057
|
* @summary Short summary of the component's intended use.
|
|
@@ -2064,6 +2080,7 @@ declare module "components/data-select/data-select.component" {
|
|
|
2064
2080
|
value: string;
|
|
2065
2081
|
/** The provider of the select. */
|
|
2066
2082
|
provider: 'color' | 'currency' | 'country' | 'phone';
|
|
2083
|
+
/** The position of the icon. */
|
|
2067
2084
|
iconPosition: 'start' | 'end' | 'none';
|
|
2068
2085
|
/** An array of keys to use for filtering the options in the selected provider. */
|
|
2069
2086
|
filter: string[];
|
|
@@ -2088,11 +2105,14 @@ declare module "components/data-select/data-select.component" {
|
|
|
2088
2105
|
helpText: string;
|
|
2089
2106
|
/** The selects required attribute. */
|
|
2090
2107
|
required: boolean;
|
|
2108
|
+
iconOnly: boolean;
|
|
2091
2109
|
protected readonly formControlController: FormControlController;
|
|
2092
2110
|
get validationMessage(): string;
|
|
2093
2111
|
get validity(): ValidityState;
|
|
2112
|
+
constructor();
|
|
2094
2113
|
connectedCallback(): void;
|
|
2095
2114
|
disconnectedCallback(): void;
|
|
2115
|
+
protected firstUpdated(_changedProperties: PropertyValues): void;
|
|
2096
2116
|
checkValidity(): boolean;
|
|
2097
2117
|
getForm(): HTMLFormElement | null;
|
|
2098
2118
|
reportValidity(): boolean;
|
|
@@ -2105,6 +2125,7 @@ declare module "components/data-select/data-select.component" {
|
|
|
2105
2125
|
blur: () => void;
|
|
2106
2126
|
protected render(): import("lit").TemplateResult<1>;
|
|
2107
2127
|
private _updatePrefix;
|
|
2128
|
+
private getPlaceholder;
|
|
2108
2129
|
}
|
|
2109
2130
|
}
|
|
2110
2131
|
declare module "components/data-select/index" {
|
|
@@ -2618,6 +2639,9 @@ declare module "components/data-table/data-table.component" {
|
|
|
2618
2639
|
filters: [];
|
|
2619
2640
|
method: 'GET' | 'POST';
|
|
2620
2641
|
noInitialLoad: boolean;
|
|
2642
|
+
groupBy: string;
|
|
2643
|
+
groups: string;
|
|
2644
|
+
selectAllButton: ZnButton;
|
|
2621
2645
|
private _initialLoad;
|
|
2622
2646
|
private _lastTableContent;
|
|
2623
2647
|
private resizeObserver;
|
|
@@ -2632,7 +2656,6 @@ declare module "components/data-table/data-table.component" {
|
|
|
2632
2656
|
private _dataTask;
|
|
2633
2657
|
private rowHasActions;
|
|
2634
2658
|
requestParams: Record<string, any>;
|
|
2635
|
-
builtinRequestParams: Record<string, any>;
|
|
2636
2659
|
refresh(): void;
|
|
2637
2660
|
render(): TemplateResult<1>;
|
|
2638
2661
|
connectedCallback(): void;
|
|
@@ -2640,6 +2663,8 @@ declare module "components/data-table/data-table.component" {
|
|
|
2640
2663
|
changeEventListener: (e: ZnFilterChangeEvent) => void;
|
|
2641
2664
|
emptyState(): TemplateResult<1>;
|
|
2642
2665
|
renderTable(data: Response): TemplateResult<1>;
|
|
2666
|
+
humanize(str: string): string;
|
|
2667
|
+
renderTableData(data: any): TemplateResult<1>;
|
|
2643
2668
|
getTableHeader(): TemplateResult<1>;
|
|
2644
2669
|
getTableFooter(): TemplateResult<1>;
|
|
2645
2670
|
getRowsSelected(): TemplateResult<1> | null;
|
|
@@ -2660,9 +2685,11 @@ declare module "components/data-table/data-table.component" {
|
|
|
2660
2685
|
private getTableSortIcon;
|
|
2661
2686
|
private renderCellHeader;
|
|
2662
2687
|
private renderCellBody;
|
|
2688
|
+
private isRowSelected;
|
|
2663
2689
|
private getRows;
|
|
2664
2690
|
private getSelectedKeys;
|
|
2665
2691
|
private updateKeys;
|
|
2692
|
+
private updateSelectAll;
|
|
2666
2693
|
private updateModifyKeys;
|
|
2667
2694
|
private updateDeleteKeys;
|
|
2668
2695
|
private extractComparable;
|
|
@@ -2816,6 +2843,13 @@ declare module "components/note/note.component" {
|
|
|
2816
2843
|
caption: string;
|
|
2817
2844
|
date: string;
|
|
2818
2845
|
body: string;
|
|
2846
|
+
collapseAtLines: number;
|
|
2847
|
+
private expanded;
|
|
2848
|
+
private _isOverflowing;
|
|
2849
|
+
private _toggleExpand;
|
|
2850
|
+
private _measureOverflow;
|
|
2851
|
+
protected firstUpdated(): void;
|
|
2852
|
+
protected updated(): void;
|
|
2819
2853
|
protected render(): unknown;
|
|
2820
2854
|
}
|
|
2821
2855
|
}
|
|
@@ -3111,6 +3145,7 @@ declare module "components/header/header.component" {
|
|
|
3111
3145
|
entityIdShow: boolean;
|
|
3112
3146
|
transparent: boolean;
|
|
3113
3147
|
caption: string;
|
|
3148
|
+
icon: string;
|
|
3114
3149
|
description: string;
|
|
3115
3150
|
navigation: never[];
|
|
3116
3151
|
fullWidth: boolean;
|
|
@@ -3441,12 +3476,14 @@ declare module "components/panel/panel.component" {
|
|
|
3441
3476
|
private readonly hasSlotController;
|
|
3442
3477
|
basis: number;
|
|
3443
3478
|
caption: string;
|
|
3479
|
+
icon: string;
|
|
3444
3480
|
description: string;
|
|
3445
3481
|
tabbed: boolean;
|
|
3446
3482
|
cosmic: boolean;
|
|
3447
3483
|
flush: boolean;
|
|
3448
3484
|
flushX: boolean;
|
|
3449
3485
|
flushY: boolean;
|
|
3486
|
+
flushFooter: boolean;
|
|
3450
3487
|
transparent: boolean;
|
|
3451
3488
|
protected firstUpdated(_changedProperties: PropertyValues): void;
|
|
3452
3489
|
connectedCallback(): void;
|
|
@@ -3955,6 +3992,24 @@ declare module "components/progress-bar/index" {
|
|
|
3955
3992
|
declare module "components/order-table/order-table.component" {
|
|
3956
3993
|
import { type CSSResultGroup } from 'lit';
|
|
3957
3994
|
import ZincElement from "internal/zinc-element";
|
|
3995
|
+
interface OrderTableData {
|
|
3996
|
+
headers: string[];
|
|
3997
|
+
items: {
|
|
3998
|
+
caption?: string;
|
|
3999
|
+
summary?: string;
|
|
4000
|
+
data: string[];
|
|
4001
|
+
sub?: {
|
|
4002
|
+
caption?: string;
|
|
4003
|
+
summary?: string;
|
|
4004
|
+
data: string[];
|
|
4005
|
+
}[];
|
|
4006
|
+
}[];
|
|
4007
|
+
tax?: string;
|
|
4008
|
+
discount?: string;
|
|
4009
|
+
total?: string;
|
|
4010
|
+
paid?: string;
|
|
4011
|
+
remaining?: string;
|
|
4012
|
+
}
|
|
3958
4013
|
/**
|
|
3959
4014
|
* @summary Short summary of the component's intended use.
|
|
3960
4015
|
* @documentation https://zinc.style/components/order-table
|
|
@@ -3974,11 +4029,12 @@ declare module "components/order-table/order-table.component" {
|
|
|
3974
4029
|
*/
|
|
3975
4030
|
export default class ZnOrderTable extends ZincElement {
|
|
3976
4031
|
static styles: CSSResultGroup;
|
|
3977
|
-
data:
|
|
4032
|
+
data: OrderTableData;
|
|
3978
4033
|
private isMobile;
|
|
3979
4034
|
private modifiedData;
|
|
3980
|
-
constructor();
|
|
3981
4035
|
connectedCallback(): void;
|
|
4036
|
+
disconnectedCallback(): void;
|
|
4037
|
+
resizeEventHandler: () => void;
|
|
3982
4038
|
render(): import("lit").TemplateResult<1>;
|
|
3983
4039
|
getHeaders(): import("lit").TemplateResult<1>;
|
|
3984
4040
|
getRows(): import("lit").TemplateResult<1>;
|
|
@@ -4222,6 +4278,7 @@ declare module "components/editor/modules/toolbar/toolbar" {
|
|
|
4222
4278
|
private _openDatePicker;
|
|
4223
4279
|
private _openDialog;
|
|
4224
4280
|
private _handleOverflowUpdate;
|
|
4281
|
+
private _addImage;
|
|
4225
4282
|
}
|
|
4226
4283
|
export default Toolbar;
|
|
4227
4284
|
}
|
|
@@ -4245,6 +4302,7 @@ declare module "components/editor/modules/attachment/attachment" {
|
|
|
4245
4302
|
constructor(quill: Quill, options: AttachmentOptions);
|
|
4246
4303
|
private _selectLocalImage;
|
|
4247
4304
|
private _fileChanged;
|
|
4305
|
+
addAttachment(file: File, dataUrl?: string): void;
|
|
4248
4306
|
private _attachmentContainer;
|
|
4249
4307
|
private _createAttachmentContainer;
|
|
4250
4308
|
private _insertAttachment;
|
|
@@ -5290,6 +5348,7 @@ declare module "components/rating/rating.component" {
|
|
|
5290
5348
|
precision: number;
|
|
5291
5349
|
readonly: boolean;
|
|
5292
5350
|
disabled: boolean;
|
|
5351
|
+
size: 'small' | 'medium' | 'large';
|
|
5293
5352
|
getSymbol: (value: number) => string;
|
|
5294
5353
|
/** Gets the validity state object */
|
|
5295
5354
|
get validity(): ValidityState;
|
|
@@ -5771,6 +5830,7 @@ declare module "components/item/item.component" {
|
|
|
5771
5830
|
alignEnd: boolean;
|
|
5772
5831
|
connectedCallback(): void;
|
|
5773
5832
|
protected updated(_changedProperties: PropertyValues): void;
|
|
5833
|
+
protected _hasContent(): boolean;
|
|
5774
5834
|
render(): import("lit").TemplateResult<1>;
|
|
5775
5835
|
}
|
|
5776
5836
|
}
|
|
@@ -6199,8 +6259,8 @@ declare module "components/split-button/index" {
|
|
|
6199
6259
|
}
|
|
6200
6260
|
}
|
|
6201
6261
|
declare module "components/content-block/content-block.component" {
|
|
6202
|
-
import ZincElement from "internal/zinc-element";
|
|
6203
6262
|
import type { PropertyValues } from 'lit';
|
|
6263
|
+
import ZincElement from "internal/zinc-element";
|
|
6204
6264
|
interface TextRow {
|
|
6205
6265
|
lines: string[];
|
|
6206
6266
|
type: 'reply' | 'text';
|
|
@@ -6217,23 +6277,28 @@ declare module "components/content-block/content-block.component" {
|
|
|
6217
6277
|
sender: string;
|
|
6218
6278
|
avatar: string;
|
|
6219
6279
|
outbound: boolean;
|
|
6280
|
+
noCollapse: boolean;
|
|
6220
6281
|
short: boolean;
|
|
6221
6282
|
defaultDisplay: 'text' | 'html';
|
|
6222
6283
|
htmlNodes: Node[];
|
|
6223
6284
|
iframe: Promise<HTMLIFrameElement>;
|
|
6224
6285
|
private readonly hasSlotController;
|
|
6225
6286
|
private _textRows;
|
|
6226
|
-
private
|
|
6287
|
+
private _footerObserver?;
|
|
6288
|
+
private _replaceDebounce;
|
|
6227
6289
|
connectedCallback(): void;
|
|
6228
6290
|
disconnectedCallback(): void;
|
|
6229
6291
|
private _collapseContent;
|
|
6230
6292
|
private _toggleText;
|
|
6231
6293
|
private _toggleHtml;
|
|
6294
|
+
private _resizeIframe;
|
|
6232
6295
|
protected firstUpdated(_changedProperties: PropertyValues): void;
|
|
6233
6296
|
protected render(): import("lit").TemplateResult<1>;
|
|
6234
6297
|
protected truncateText(): string;
|
|
6298
|
+
private _handleSlotChange;
|
|
6299
|
+
private _debouncedReplace;
|
|
6300
|
+
private _replaceImagePlaceholders;
|
|
6235
6301
|
protected getTextSections(): TextRow[];
|
|
6236
|
-
private transformLineForImages;
|
|
6237
6302
|
showReply(e: MouseEvent): void;
|
|
6238
6303
|
}
|
|
6239
6304
|
}
|