@streamline-pulse/formkrafter-wc 0.21.0 → 0.23.0
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/components/fk-brick-actions.js +1 -1
- package/dist/components/fk-brick-list.js +1 -1
- package/dist/components/fk-brick-mold-item.js +1 -1
- package/dist/components/fk-brick-render.js +1 -1
- package/dist/components/fk-data-grid.js +1 -1
- package/dist/components/fk-drop-area.js +1 -1
- package/dist/components/fk-empty-form.js +1 -1
- package/dist/components/fk-file-input.js +1 -1
- package/dist/components/fk-form-builder.js +1 -1
- package/dist/components/fk-form-render.js +1 -1
- package/dist/components/fk-form-review.d.ts +11 -0
- package/dist/components/fk-form-review.js +1 -0
- package/dist/components/fk-property-panel.js +1 -1
- package/dist/components/fk-rules-editor.js +1 -1
- package/dist/components/fk-select-input.js +1 -1
- package/dist/components/fk-signature-input.js +1 -1
- package/dist/components/fk-stepper.js +1 -1
- package/dist/components/fk-tabs.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/{p-CWqEmA8p.js → p-0sDICgJ3.js} +1 -1
- package/dist/components/p-1_c29Rag.js +1 -0
- package/dist/components/{p-Dseq5Dgf.js → p-BOZ5pg73.js} +1 -1
- package/dist/components/{p-HXtoKsEx.js → p-BPwPAGJq.js} +1 -1
- package/dist/components/{p-D0vzpQtg.js → p-BmSNDWrx.js} +1 -1
- package/dist/components/{p-BFUJv0mU.js → p-BpDsZSJX.js} +1 -1
- package/dist/components/{p-B8iS2Kfi.js → p-CgWxWEuI.js} +1 -1
- package/dist/components/p-D0fTMJ2D.js +1 -0
- package/dist/components/{p-BypSt35U.js → p-D6WtQeaQ.js} +7 -7
- package/dist/components/{p-1ONICifP.js → p-DCKXkdxG.js} +1 -1
- package/dist/components/{p-DumoqCP0.js → p-DLYnonbs.js} +1 -1
- package/dist/components/p-DitxNIT2.js +1 -0
- package/dist/components/{p-ChWBbax4.js → p-DzPxItO6.js} +1 -1
- package/dist/components/{p-B6O_oDBF.js → p-KYwjk9Yt.js} +1 -1
- package/dist/components/{p-D1eyzDcY.js → p-XP4h_v8Q.js} +1 -1
- package/dist/formkrafter-wc/formkrafter-wc.css +1 -1
- package/dist/formkrafter-wc/formkrafter-wc.esm.js +1 -1
- package/dist/formkrafter-wc/index.esm.js +1 -1
- package/dist/formkrafter-wc/{p-87fbf005.entry.js → p-0521c981.entry.js} +1 -1
- package/dist/formkrafter-wc/p-7bf6a9d1.entry.js +1 -0
- package/dist/formkrafter-wc/{p-CVCwXROd.js → p-7kO7VDbG.js} +7 -7
- package/dist/formkrafter-wc/p-987a6904.entry.js +1 -0
- package/dist/types/components/fk-brick-render/fk-brick-render.d.ts +7 -2
- package/dist/types/components/fk-form-render/fk-form-render.d.ts +9 -1
- package/dist/types/components/fk-form-review/fk-form-review.d.ts +24 -0
- package/dist/types/components.d.ts +132 -4
- package/dist/types/index.d.ts +1 -1
- package/dist/types/utils/events.d.ts +10 -0
- package/package.json +2 -2
- package/dist/components/p-Cw3ipjvW.js +0 -1
- package/dist/components/p-D5-mBASz.js +0 -1
- package/dist/components/p-DCIGY0T9.js +0 -1
- package/dist/formkrafter-wc/p-2d48803d.entry.js +0 -1
|
@@ -5,10 +5,10 @@
|
|
|
5
5
|
* It contains typing information for all components that exist in this project.
|
|
6
6
|
*/
|
|
7
7
|
import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
|
|
8
|
-
import { BrickConfigsChangeDetail, BrickDropDetail, BrickPathDetail, BrickRulesChangeDetail, BrickStylesChangeDetail, BrickValidationsChangeDetail, DataChangeDetail, SpecChangeDetail, ValidityChangeDetail } from "./utils/events";
|
|
9
|
-
import { BrickMold, BrickSpec, UploadedFile, Utils, ValidationResult } from "@streamline-pulse/formkrafter-core";
|
|
10
|
-
export { BrickConfigsChangeDetail, BrickDropDetail, BrickPathDetail, BrickRulesChangeDetail, BrickStylesChangeDetail, BrickValidationsChangeDetail, DataChangeDetail, SpecChangeDetail, ValidityChangeDetail } from "./utils/events";
|
|
11
|
-
export { BrickMold, BrickSpec, UploadedFile, Utils, ValidationResult } from "@streamline-pulse/formkrafter-core";
|
|
8
|
+
import { BrickConfigsChangeDetail, BrickDropDetail, BrickPathDetail, BrickReviewChangeDetail, BrickRulesChangeDetail, BrickStylesChangeDetail, BrickValidationsChangeDetail, DataChangeDetail, ReviewChangeDetail, SpecChangeDetail, ValidityChangeDetail } from "./utils/events";
|
|
9
|
+
import { BrickMold, BrickSpec, FieldAnnotations, UploadedFile, Utils, ValidationResult } from "@streamline-pulse/formkrafter-core";
|
|
10
|
+
export { BrickConfigsChangeDetail, BrickDropDetail, BrickPathDetail, BrickReviewChangeDetail, BrickRulesChangeDetail, BrickStylesChangeDetail, BrickValidationsChangeDetail, DataChangeDetail, ReviewChangeDetail, SpecChangeDetail, ValidityChangeDetail } from "./utils/events";
|
|
11
|
+
export { BrickMold, BrickSpec, FieldAnnotations, UploadedFile, Utils, ValidationResult } from "@streamline-pulse/formkrafter-core";
|
|
12
12
|
export namespace Components {
|
|
13
13
|
interface FkBrickActions {
|
|
14
14
|
"path": string;
|
|
@@ -26,6 +26,7 @@ export namespace Components {
|
|
|
26
26
|
interface FkBrickNotFound {
|
|
27
27
|
}
|
|
28
28
|
interface FkBrickRender {
|
|
29
|
+
"annotations"?: FieldAnnotations;
|
|
29
30
|
"brickSpec": BrickSpec;
|
|
30
31
|
"data"?: Record<string, unknown>;
|
|
31
32
|
"dataMap"?: Record<string, unknown>;
|
|
@@ -37,11 +38,13 @@ export namespace Components {
|
|
|
37
38
|
* @default false
|
|
38
39
|
*/
|
|
39
40
|
"editable": boolean;
|
|
41
|
+
"editableKeys"?: string[];
|
|
40
42
|
/**
|
|
41
43
|
* @default {}
|
|
42
44
|
*/
|
|
43
45
|
"errors": Record<string, string>;
|
|
44
46
|
"locale"?: string;
|
|
47
|
+
"notes"?: FieldAnnotations;
|
|
45
48
|
/**
|
|
46
49
|
* @default '0'
|
|
47
50
|
*/
|
|
@@ -50,6 +53,10 @@ export namespace Components {
|
|
|
50
53
|
* @default false
|
|
51
54
|
*/
|
|
52
55
|
"readOnly": boolean;
|
|
56
|
+
/**
|
|
57
|
+
* @default false
|
|
58
|
+
*/
|
|
59
|
+
"reviewable": boolean;
|
|
53
60
|
"rootSpec"?: BrickSpec;
|
|
54
61
|
"selectedPath"?: string;
|
|
55
62
|
"utils": Utils;
|
|
@@ -116,6 +123,10 @@ export namespace Components {
|
|
|
116
123
|
"spec"?: BrickSpec;
|
|
117
124
|
}
|
|
118
125
|
interface FkFormRender {
|
|
126
|
+
/**
|
|
127
|
+
* Reviewer notes shown under the matching fields (by brick key).
|
|
128
|
+
*/
|
|
129
|
+
"annotations"?: FieldAnnotations;
|
|
119
130
|
"context"?: Record<string, unknown>;
|
|
120
131
|
"data"?: Record<string, unknown>;
|
|
121
132
|
/**
|
|
@@ -126,11 +137,24 @@ export namespace Components {
|
|
|
126
137
|
* @default false
|
|
127
138
|
*/
|
|
128
139
|
"editable": boolean;
|
|
140
|
+
/**
|
|
141
|
+
* When set, only these keys stay editable; every other field renders read-only.
|
|
142
|
+
*/
|
|
143
|
+
"editableKeys"?: string[];
|
|
129
144
|
"locale"?: string;
|
|
145
|
+
/**
|
|
146
|
+
* An earlier review's verdicts, shown as reminders under the fields in any mode.
|
|
147
|
+
*/
|
|
148
|
+
"notes"?: FieldAnnotations;
|
|
130
149
|
/**
|
|
131
150
|
* @default false
|
|
132
151
|
*/
|
|
133
152
|
"readOnly": boolean;
|
|
153
|
+
/**
|
|
154
|
+
* Used by fk-form-review: render the flag and comment controls under each field.
|
|
155
|
+
* @default false
|
|
156
|
+
*/
|
|
157
|
+
"reviewable": boolean;
|
|
134
158
|
"selectedPath"?: string;
|
|
135
159
|
/**
|
|
136
160
|
* @default false
|
|
@@ -141,6 +165,25 @@ export namespace Components {
|
|
|
141
165
|
"submitLabel"?: string;
|
|
142
166
|
"validate": () => Promise<ValidationResult>;
|
|
143
167
|
}
|
|
168
|
+
/**
|
|
169
|
+
* A filled form, read-only, where a reviewer flags fields as incorrect and
|
|
170
|
+
* comments them. Rendering is delegated to fk-form-render; this element only
|
|
171
|
+
* holds the review map and emits it.
|
|
172
|
+
*/
|
|
173
|
+
interface FkFormReview {
|
|
174
|
+
"context"?: Record<string, unknown>;
|
|
175
|
+
"data"?: Record<string, unknown>;
|
|
176
|
+
"locale"?: string;
|
|
177
|
+
/**
|
|
178
|
+
* An earlier review's verdicts, shown as reminders so the reviewer looks at those fields again.
|
|
179
|
+
*/
|
|
180
|
+
"notes"?: FieldAnnotations;
|
|
181
|
+
/**
|
|
182
|
+
* Existing annotations to start from (by brick key).
|
|
183
|
+
*/
|
|
184
|
+
"reviews"?: FieldAnnotations;
|
|
185
|
+
"spec": BrickSpec;
|
|
186
|
+
}
|
|
144
187
|
interface FkPropertyPanel {
|
|
145
188
|
"brick": BrickSpec;
|
|
146
189
|
"editLocale"?: string;
|
|
@@ -251,6 +294,10 @@ export interface FkFormRenderCustomEvent<T> extends CustomEvent<T> {
|
|
|
251
294
|
detail: T;
|
|
252
295
|
target: HTMLFkFormRenderElement;
|
|
253
296
|
}
|
|
297
|
+
export interface FkFormReviewCustomEvent<T> extends CustomEvent<T> {
|
|
298
|
+
detail: T;
|
|
299
|
+
target: HTMLFkFormReviewElement;
|
|
300
|
+
}
|
|
254
301
|
export interface FkPropertyPanelCustomEvent<T> extends CustomEvent<T> {
|
|
255
302
|
detail: T;
|
|
256
303
|
target: HTMLFkPropertyPanelElement;
|
|
@@ -322,6 +369,7 @@ declare global {
|
|
|
322
369
|
"brickRulesChange": BrickRulesChangeDetail;
|
|
323
370
|
"brickRemove": BrickPathDetail;
|
|
324
371
|
"brickDuplicate": BrickPathDetail;
|
|
372
|
+
"brickReviewChange": BrickReviewChangeDetail;
|
|
325
373
|
}
|
|
326
374
|
interface HTMLFkBrickRenderElement extends Components.FkBrickRender, HTMLStencilElement {
|
|
327
375
|
addEventListener<K extends keyof HTMLFkBrickRenderElementEventMap>(type: K, listener: (this: HTMLFkBrickRenderElement, ev: FkBrickRenderCustomEvent<HTMLFkBrickRenderElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
@@ -447,6 +495,28 @@ declare global {
|
|
|
447
495
|
prototype: HTMLFkFormRenderElement;
|
|
448
496
|
new (): HTMLFkFormRenderElement;
|
|
449
497
|
};
|
|
498
|
+
interface HTMLFkFormReviewElementEventMap {
|
|
499
|
+
"reviewChange": ReviewChangeDetail;
|
|
500
|
+
}
|
|
501
|
+
/**
|
|
502
|
+
* A filled form, read-only, where a reviewer flags fields as incorrect and
|
|
503
|
+
* comments them. Rendering is delegated to fk-form-render; this element only
|
|
504
|
+
* holds the review map and emits it.
|
|
505
|
+
*/
|
|
506
|
+
interface HTMLFkFormReviewElement extends Components.FkFormReview, HTMLStencilElement {
|
|
507
|
+
addEventListener<K extends keyof HTMLFkFormReviewElementEventMap>(type: K, listener: (this: HTMLFkFormReviewElement, ev: FkFormReviewCustomEvent<HTMLFkFormReviewElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
508
|
+
addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
509
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
510
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
511
|
+
removeEventListener<K extends keyof HTMLFkFormReviewElementEventMap>(type: K, listener: (this: HTMLFkFormReviewElement, ev: FkFormReviewCustomEvent<HTMLFkFormReviewElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
|
|
512
|
+
removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
513
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
514
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
515
|
+
}
|
|
516
|
+
var HTMLFkFormReviewElement: {
|
|
517
|
+
prototype: HTMLFkFormReviewElement;
|
|
518
|
+
new (): HTMLFkFormReviewElement;
|
|
519
|
+
};
|
|
450
520
|
interface HTMLFkPropertyPanelElementEventMap {
|
|
451
521
|
"brickConfigsChange": BrickConfigsChangeDetail;
|
|
452
522
|
"brickValidationsChange": BrickValidationsChangeDetail;
|
|
@@ -565,6 +635,7 @@ declare global {
|
|
|
565
635
|
"fk-file-input": HTMLFkFileInputElement;
|
|
566
636
|
"fk-form-builder": HTMLFkFormBuilderElement;
|
|
567
637
|
"fk-form-render": HTMLFkFormRenderElement;
|
|
638
|
+
"fk-form-review": HTMLFkFormReviewElement;
|
|
568
639
|
"fk-property-panel": HTMLFkPropertyPanelElement;
|
|
569
640
|
"fk-rules-editor": HTMLFkRulesEditorElement;
|
|
570
641
|
"fk-select-input": HTMLFkSelectInputElement;
|
|
@@ -596,6 +667,7 @@ declare namespace LocalJSX {
|
|
|
596
667
|
interface FkBrickNotFound {
|
|
597
668
|
}
|
|
598
669
|
interface FkBrickRender {
|
|
670
|
+
"annotations"?: FieldAnnotations;
|
|
599
671
|
"brickSpec": BrickSpec;
|
|
600
672
|
"data"?: Record<string, unknown>;
|
|
601
673
|
"dataMap"?: Record<string, unknown>;
|
|
@@ -607,15 +679,18 @@ declare namespace LocalJSX {
|
|
|
607
679
|
* @default false
|
|
608
680
|
*/
|
|
609
681
|
"editable"?: boolean;
|
|
682
|
+
"editableKeys"?: string[];
|
|
610
683
|
/**
|
|
611
684
|
* @default {}
|
|
612
685
|
*/
|
|
613
686
|
"errors"?: Record<string, string>;
|
|
614
687
|
"locale"?: string;
|
|
688
|
+
"notes"?: FieldAnnotations;
|
|
615
689
|
"onBrickConfigsChange"?: (event: FkBrickRenderCustomEvent<BrickConfigsChangeDetail>) => void;
|
|
616
690
|
"onBrickDataChange"?: (event: FkBrickRenderCustomEvent<Record<string, unknown>>) => void;
|
|
617
691
|
"onBrickDuplicate"?: (event: FkBrickRenderCustomEvent<BrickPathDetail>) => void;
|
|
618
692
|
"onBrickRemove"?: (event: FkBrickRenderCustomEvent<BrickPathDetail>) => void;
|
|
693
|
+
"onBrickReviewChange"?: (event: FkBrickRenderCustomEvent<BrickReviewChangeDetail>) => void;
|
|
619
694
|
"onBrickRulesChange"?: (event: FkBrickRenderCustomEvent<BrickRulesChangeDetail>) => void;
|
|
620
695
|
"onBrickStylesChange"?: (event: FkBrickRenderCustomEvent<BrickStylesChangeDetail>) => void;
|
|
621
696
|
"onBrickValidationsChange"?: (event: FkBrickRenderCustomEvent<BrickValidationsChangeDetail>) => void;
|
|
@@ -627,6 +702,10 @@ declare namespace LocalJSX {
|
|
|
627
702
|
* @default false
|
|
628
703
|
*/
|
|
629
704
|
"readOnly"?: boolean;
|
|
705
|
+
/**
|
|
706
|
+
* @default false
|
|
707
|
+
*/
|
|
708
|
+
"reviewable"?: boolean;
|
|
630
709
|
"rootSpec"?: BrickSpec;
|
|
631
710
|
"selectedPath"?: string;
|
|
632
711
|
"utils": Utils;
|
|
@@ -697,6 +776,10 @@ declare namespace LocalJSX {
|
|
|
697
776
|
"spec"?: BrickSpec;
|
|
698
777
|
}
|
|
699
778
|
interface FkFormRender {
|
|
779
|
+
/**
|
|
780
|
+
* Reviewer notes shown under the matching fields (by brick key).
|
|
781
|
+
*/
|
|
782
|
+
"annotations"?: FieldAnnotations;
|
|
700
783
|
"context"?: Record<string, unknown>;
|
|
701
784
|
"data"?: Record<string, unknown>;
|
|
702
785
|
/**
|
|
@@ -707,6 +790,10 @@ declare namespace LocalJSX {
|
|
|
707
790
|
* @default false
|
|
708
791
|
*/
|
|
709
792
|
"editable"?: boolean;
|
|
793
|
+
/**
|
|
794
|
+
* When set, only these keys stay editable; every other field renders read-only.
|
|
795
|
+
*/
|
|
796
|
+
"editableKeys"?: string[];
|
|
710
797
|
/**
|
|
711
798
|
* The `id` of a `<form>` element to associate this element with.
|
|
712
799
|
*/
|
|
@@ -716,6 +803,10 @@ declare namespace LocalJSX {
|
|
|
716
803
|
* The name of the element, used when submitting an HTML form.
|
|
717
804
|
*/
|
|
718
805
|
"name"?: string;
|
|
806
|
+
/**
|
|
807
|
+
* An earlier review's verdicts, shown as reminders under the fields in any mode.
|
|
808
|
+
*/
|
|
809
|
+
"notes"?: FieldAnnotations;
|
|
719
810
|
"onFormDataChange"?: (event: FkFormRenderCustomEvent<DataChangeDetail>) => void;
|
|
720
811
|
"onFormSubmit"?: (event: FkFormRenderCustomEvent<DataChangeDetail>) => void;
|
|
721
812
|
"onValidityChange"?: (event: FkFormRenderCustomEvent<ValidityChangeDetail>) => void;
|
|
@@ -723,6 +814,11 @@ declare namespace LocalJSX {
|
|
|
723
814
|
* @default false
|
|
724
815
|
*/
|
|
725
816
|
"readOnly"?: boolean;
|
|
817
|
+
/**
|
|
818
|
+
* Used by fk-form-review: render the flag and comment controls under each field.
|
|
819
|
+
* @default false
|
|
820
|
+
*/
|
|
821
|
+
"reviewable"?: boolean;
|
|
726
822
|
"selectedPath"?: string;
|
|
727
823
|
/**
|
|
728
824
|
* @default false
|
|
@@ -731,6 +827,26 @@ declare namespace LocalJSX {
|
|
|
731
827
|
"spec": BrickSpec;
|
|
732
828
|
"submitLabel"?: string;
|
|
733
829
|
}
|
|
830
|
+
/**
|
|
831
|
+
* A filled form, read-only, where a reviewer flags fields as incorrect and
|
|
832
|
+
* comments them. Rendering is delegated to fk-form-render; this element only
|
|
833
|
+
* holds the review map and emits it.
|
|
834
|
+
*/
|
|
835
|
+
interface FkFormReview {
|
|
836
|
+
"context"?: Record<string, unknown>;
|
|
837
|
+
"data"?: Record<string, unknown>;
|
|
838
|
+
"locale"?: string;
|
|
839
|
+
/**
|
|
840
|
+
* An earlier review's verdicts, shown as reminders so the reviewer looks at those fields again.
|
|
841
|
+
*/
|
|
842
|
+
"notes"?: FieldAnnotations;
|
|
843
|
+
"onReviewChange"?: (event: FkFormReviewCustomEvent<ReviewChangeDetail>) => void;
|
|
844
|
+
/**
|
|
845
|
+
* Existing annotations to start from (by brick key).
|
|
846
|
+
*/
|
|
847
|
+
"reviews"?: FieldAnnotations;
|
|
848
|
+
"spec": BrickSpec;
|
|
849
|
+
}
|
|
734
850
|
interface FkPropertyPanel {
|
|
735
851
|
"brick": BrickSpec;
|
|
736
852
|
"editLocale"?: string;
|
|
@@ -831,6 +947,7 @@ declare namespace LocalJSX {
|
|
|
831
947
|
"readOnly": boolean;
|
|
832
948
|
"disabled": boolean;
|
|
833
949
|
"selectedPath": string;
|
|
950
|
+
"reviewable": boolean;
|
|
834
951
|
"locale": string;
|
|
835
952
|
}
|
|
836
953
|
interface FkCodeEditorAttributes {
|
|
@@ -863,6 +980,10 @@ declare namespace LocalJSX {
|
|
|
863
980
|
"submitLabel": string;
|
|
864
981
|
"selectedPath": string;
|
|
865
982
|
"locale": string;
|
|
983
|
+
"reviewable": boolean;
|
|
984
|
+
}
|
|
985
|
+
interface FkFormReviewAttributes {
|
|
986
|
+
"locale": string;
|
|
866
987
|
}
|
|
867
988
|
interface FkPropertyPanelAttributes {
|
|
868
989
|
"path": string;
|
|
@@ -906,6 +1027,7 @@ declare namespace LocalJSX {
|
|
|
906
1027
|
"fk-file-input": Omit<FkFileInput, keyof FkFileInputAttributes> & { [K in keyof FkFileInput & keyof FkFileInputAttributes]?: FkFileInput[K] } & { [K in keyof FkFileInput & keyof FkFileInputAttributes as `attr:${K}`]?: FkFileInputAttributes[K] } & { [K in keyof FkFileInput & keyof FkFileInputAttributes as `prop:${K}`]?: FkFileInput[K] };
|
|
907
1028
|
"fk-form-builder": Omit<FkFormBuilder, keyof FkFormBuilderAttributes> & { [K in keyof FkFormBuilder & keyof FkFormBuilderAttributes]?: FkFormBuilder[K] } & { [K in keyof FkFormBuilder & keyof FkFormBuilderAttributes as `attr:${K}`]?: FkFormBuilderAttributes[K] } & { [K in keyof FkFormBuilder & keyof FkFormBuilderAttributes as `prop:${K}`]?: FkFormBuilder[K] };
|
|
908
1029
|
"fk-form-render": Omit<FkFormRender, keyof FkFormRenderAttributes> & { [K in keyof FkFormRender & keyof FkFormRenderAttributes]?: FkFormRender[K] } & { [K in keyof FkFormRender & keyof FkFormRenderAttributes as `attr:${K}`]?: FkFormRenderAttributes[K] } & { [K in keyof FkFormRender & keyof FkFormRenderAttributes as `prop:${K}`]?: FkFormRender[K] };
|
|
1030
|
+
"fk-form-review": Omit<FkFormReview, keyof FkFormReviewAttributes> & { [K in keyof FkFormReview & keyof FkFormReviewAttributes]?: FkFormReview[K] } & { [K in keyof FkFormReview & keyof FkFormReviewAttributes as `attr:${K}`]?: FkFormReviewAttributes[K] } & { [K in keyof FkFormReview & keyof FkFormReviewAttributes as `prop:${K}`]?: FkFormReview[K] };
|
|
909
1031
|
"fk-property-panel": Omit<FkPropertyPanel, keyof FkPropertyPanelAttributes> & { [K in keyof FkPropertyPanel & keyof FkPropertyPanelAttributes]?: FkPropertyPanel[K] } & { [K in keyof FkPropertyPanel & keyof FkPropertyPanelAttributes as `attr:${K}`]?: FkPropertyPanelAttributes[K] } & { [K in keyof FkPropertyPanel & keyof FkPropertyPanelAttributes as `prop:${K}`]?: FkPropertyPanel[K] };
|
|
910
1032
|
"fk-rules-editor": Omit<FkRulesEditor, keyof FkRulesEditorAttributes> & { [K in keyof FkRulesEditor & keyof FkRulesEditorAttributes]?: FkRulesEditor[K] } & { [K in keyof FkRulesEditor & keyof FkRulesEditorAttributes as `attr:${K}`]?: FkRulesEditorAttributes[K] } & { [K in keyof FkRulesEditor & keyof FkRulesEditorAttributes as `prop:${K}`]?: FkRulesEditor[K] };
|
|
911
1033
|
"fk-select-input": Omit<FkSelectInput, keyof FkSelectInputAttributes> & { [K in keyof FkSelectInput & keyof FkSelectInputAttributes]?: FkSelectInput[K] } & { [K in keyof FkSelectInput & keyof FkSelectInputAttributes as `attr:${K}`]?: FkSelectInputAttributes[K] } & { [K in keyof FkSelectInput & keyof FkSelectInputAttributes as `prop:${K}`]?: FkSelectInput[K] };
|
|
@@ -930,6 +1052,12 @@ declare module "@stencil/core" {
|
|
|
930
1052
|
"fk-file-input": LocalJSX.IntrinsicElements["fk-file-input"] & JSXBase.HTMLAttributes<HTMLFkFileInputElement>;
|
|
931
1053
|
"fk-form-builder": LocalJSX.IntrinsicElements["fk-form-builder"] & JSXBase.HTMLAttributes<HTMLFkFormBuilderElement>;
|
|
932
1054
|
"fk-form-render": LocalJSX.IntrinsicElements["fk-form-render"] & JSXBase.HTMLAttributes<HTMLFkFormRenderElement>;
|
|
1055
|
+
/**
|
|
1056
|
+
* A filled form, read-only, where a reviewer flags fields as incorrect and
|
|
1057
|
+
* comments them. Rendering is delegated to fk-form-render; this element only
|
|
1058
|
+
* holds the review map and emits it.
|
|
1059
|
+
*/
|
|
1060
|
+
"fk-form-review": LocalJSX.IntrinsicElements["fk-form-review"] & JSXBase.HTMLAttributes<HTMLFkFormReviewElement>;
|
|
933
1061
|
"fk-property-panel": LocalJSX.IntrinsicElements["fk-property-panel"] & JSXBase.HTMLAttributes<HTMLFkPropertyPanelElement>;
|
|
934
1062
|
"fk-rules-editor": LocalJSX.IntrinsicElements["fk-rules-editor"] & JSXBase.HTMLAttributes<HTMLFkRulesEditorElement>;
|
|
935
1063
|
"fk-select-input": LocalJSX.IntrinsicElements["fk-select-input"] & JSXBase.HTMLAttributes<HTMLFkSelectInputElement>;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -6,6 +6,6 @@ export type { AnyBrick } from './registry/registry';
|
|
|
6
6
|
export { createBrick } from './registry/create-brick';
|
|
7
7
|
export type { WcBrickConfigs, WcBrickProps, BrickRenderFn } from './registry/create-brick';
|
|
8
8
|
export { registerDefaultBricks, textInputBrick, emailBrick, passwordBrick, urlBrick, phoneBrick, textareaBrick, numberBrick, dateBrick, timeBrick, datetimeBrick, selectBrick, multiSelectBrick, radioBrick, selectBoxesBrick, checkboxBrick, tagsBrick, signatureBrick, addressBrick, codeBrick, fileBrick, dataGridBrick, hiddenBrick, contentBrick, recapBrick, nestedFormBrick, groupBrick, rowBrick, columnBrick, stepperBrick, tabsBrick, } from './registry/default-bricks';
|
|
9
|
-
export type { BrickDropDetail, BrickConfigsChangeDetail, BrickStylesChangeDetail, BrickValidationsChangeDetail, BrickRulesChangeDetail, BrickPathDetail, SpecChangeDetail, DataChangeDetail, } from './utils/events';
|
|
9
|
+
export type { BrickDropDetail, BrickConfigsChangeDetail, BrickStylesChangeDetail, BrickValidationsChangeDetail, BrickRulesChangeDetail, BrickPathDetail, SpecChangeDetail, DataChangeDetail, BrickReviewChangeDetail, ReviewChangeDetail, } from './utils/events';
|
|
10
10
|
export { setFkTranslations, fkT, fkTOr, frFkTranslations } from './i18n/i18n';
|
|
11
11
|
export type { FkTranslations } from './i18n/i18n';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { FieldAnnotation, FieldAnnotations } from '@streamline-pulse/formkrafter-core';
|
|
1
2
|
import type { BrickBaseConfigs, BrickMold, BrickSpec, BrickStyles, Operation, Rule, Validation } from '@streamline-pulse/formkrafter-core';
|
|
2
3
|
export interface BrickDropDetail {
|
|
3
4
|
source: 'new' | 'move';
|
|
@@ -30,6 +31,15 @@ export interface SpecChangeDetail {
|
|
|
30
31
|
patches: Operation[];
|
|
31
32
|
inverse: Operation[];
|
|
32
33
|
}
|
|
34
|
+
export interface BrickReviewChangeDetail {
|
|
35
|
+
key: string;
|
|
36
|
+
annotation: FieldAnnotation;
|
|
37
|
+
}
|
|
38
|
+
export interface ReviewChangeDetail {
|
|
39
|
+
reviews: FieldAnnotations;
|
|
40
|
+
/** Keys flagged as incorrect, in spec order of first flagging. */
|
|
41
|
+
flagged: string[];
|
|
42
|
+
}
|
|
33
43
|
export interface ValidityChangeDetail {
|
|
34
44
|
valid: boolean;
|
|
35
45
|
errors: Record<string, string>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamline-pulse/formkrafter-wc",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.23.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "FormKrafter web components (Stencil)",
|
|
6
6
|
"main": "dist/components/index.js",
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
"@codemirror/state": "^6.7.1",
|
|
63
63
|
"@codemirror/theme-one-dark": "^6.1.3",
|
|
64
64
|
"@codemirror/view": "^6.43.6",
|
|
65
|
-
"@streamline-pulse/formkrafter-core": "0.
|
|
65
|
+
"@streamline-pulse/formkrafter-core": "0.23.0"
|
|
66
66
|
},
|
|
67
67
|
"devDependencies": {
|
|
68
68
|
"@stencil/core": "^4.43.5",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t,p as s,H as i,c as e,h as a}from"./p-B29HakDD.js";import{g as r,r as h,a as n,w as o}from"./p-BypSt35U.js";import{g as l}from"./p-BMtyMU2R.js";import{d as c}from"./p-1ONICifP.js";import{d}from"./p-BTxz9ZnS.js";import{d as p}from"./p-B6O_oDBF.js";const k=s(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.brickDataChange=e(this,"brickDataChange"),this.brickConfigsChange=e(this,"brickConfigsChange"),this.brickStylesChange=e(this,"brickStylesChange"),this.brickValidationsChange=e(this,"brickValidationsChange"),this.brickRulesChange=e(this,"brickRulesChange"),this.brickRemove=e(this,"brickRemove"),this.brickDuplicate=e(this,"brickDuplicate"),this.path="0",this.editable=!1,this.readOnly=!1,this.disabled=!1,this.errors={}}render(){var t,s,i,e,c;const d=this.brickSpec;if(!d)return null;const p=l(d.type,d.id);if(!p)return a("fk-brick-not-found",null,`${d.type}:${d.id}`);const k=this.editable&&(null===(t=d.editable)||void 0===t||t),u=r(d.rules,this.dataMap);if(!k&&!0===u.hidden)return null;const f="panel"===d.type||"collection"===d.type,b=(null!==(s=d.children)&&void 0!==s?s:[]).map(((t,s)=>{var i;return a("fk-brick-render",{brickSpec:t,rootSpec:null!==(i=this.rootSpec)&&void 0!==i?i:this.brickSpec,data:this.data,dataMap:this.dataMap,errors:this.errors,locale:this.locale,path:`${this.path}.${s}`,editable:this.editable,readOnly:this.readOnly,disabled:this.disabled,selectedPath:this.selectedPath,utils:this.utils})}));k&&f&&b.push(a("fk-drop-area",{path:this.path}));const m={brickSpec:d,configsForm:d.configsForm,configs:h(d.configs,this.locale),locale:this.locale,styles:null!==(i=d.styles)&&void 0!==i?i:{},data:n(d,this.data),dataMap:this.dataMap,rootSpec:null!==(e=this.rootSpec)&&void 0!==e?e:this.brickSpec,error:(null===(c=d.configs)||void 0===c?void 0:c.key)?this.errors[d.configs.key]:void 0,disabled:!k&&(this.disabled||!0===u.disabled),readOnly:!k&&this.readOnly,path:this.path,editable:k,children:b,validations:d.validations,rules:d.rules,utils:this.utils,onDataChange:t=>{const s=o(d,t);void 0!==s&&this.brickDataChange.emit(s)},onConfigsChange:(t,s)=>this.brickConfigsChange.emit({configs:t,path:null!=s?s:this.path}),onStylesChange:(t,s)=>this.brickStylesChange.emit({styles:t,path:null!=s?s:this.path}),onValidationsChange:(t,s)=>this.brickValidationsChange.emit({validations:t,path:null!=s?s:this.path}),onRulesChange:(t,s)=>this.brickRulesChange.emit({rules:t,path:null!=s?s:this.path}),onDelete:t=>this.brickRemove.emit({path:t}),onDuplicate:t=>this.brickDuplicate.emit({path:t})},g=k?p.renderBuilder(m):p.render(m);return k&&"0"!==this.path?a("fk-brick-actions",{path:this.path,selected:this.path===this.selectedPath},g):g}},[0,"fk-brick-render",{brickSpec:[16],rootSpec:[16],data:[16],dataMap:[16],path:[1],editable:[4],readOnly:[4,"read-only"],disabled:[4],selectedPath:[1,"selected-path"],errors:[16],locale:[1],utils:[16]}]);function u(){"undefined"!=typeof customElements&&["fk-brick-render","fk-brick-actions","fk-brick-not-found","fk-brick-render","fk-drop-area"].forEach((s=>{switch(s){case"fk-brick-render":customElements.get(t(s))||customElements.define(t(s),k);break;case"fk-brick-actions":customElements.get(t(s))||c();break;case"fk-brick-not-found":customElements.get(t(s))||d();break;case"fk-brick-render":customElements.get(t(s))||u();break;case"fk-drop-area":customElements.get(t(s))||p()}}))}u();export{k as F,u as d}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t,p as s,H as i,c as e,h as r}from"./p-B29HakDD.js";import{b as a,d as o,h as n,e as c,i as h,g as d,v as l}from"./p-BypSt35U.js";import{registerDefaultBricks as f}from"./index.js";import{d as m}from"./p-1ONICifP.js";import{d as u}from"./p-BTxz9ZnS.js";import{d as p}from"./p-Cw3ipjvW.js";import{d as b}from"./p-CIGtlYQn.js";import{d as k}from"./p-D0vzpQtg.js";import{d as v}from"./p-B6O_oDBF.js";import{d as j}from"./p-HXtoKsEx.js";import{d as y}from"./p-ChWBbax4.js";import{d as g}from"./p-BFUJv0mU.js";import{d as O}from"./p-D1eyzDcY.js";import{d as S}from"./p-DCIGY0T9.js";const E=s(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.formDataChange=e(this,"formDataChange"),this.formSubmit=e(this,"formSubmit"),this.validityChange=e(this,"validityChange"),this.editable=!1,this.readOnly=!1,this.disabled=!1,this.showSubmit=!1,this.currentData={},this.touched={},this.expanding=!1,this.utils={validateForm:()=>({isValid:this.runValidation().valid})}}componentWillLoad(){return f(),this.attachFormInternals(),this.currentData=this.seeded(this.data),this.runExpansion()}syncData(t){this.currentData=this.seeded(t)}onSpecChange(){this.currentData=this.seeded(this.data),this.runExpansion()}componentDidLoad(){this.emitValidity()}emitValidity(t){const{valid:s,errors:i}=null!=t?t:this.runValidation(),e=`${s}|${Object.keys(i).sort().join(",")}`;e!==this.lastValidity&&(this.lastValidity=e,this.validityChange.emit({valid:s,errors:i}),this.reportToForm(s,i))}attachFormInternals(){const t=this.host;if("function"==typeof t.attachInternals)try{this.internals=t.attachInternals()}catch(t){this.internals=void 0}}reportToForm(t,s){var i,e,r;if(null===(i=this.internals)||void 0===i?void 0:i.setValidity)try{this.internals.setFormValue(JSON.stringify(this.publicData())),t?this.internals.setValidity({}):this.internals.setValidity({customError:!0},null!==(e=Object.values(s)[0])&&void 0!==e?e:a("form.invalid"),null!==(r=this.host.querySelector("input, select, textarea"))&&void 0!==r?r:void 0)}catch(t){}}handleHostFormSubmit(t){var s;const i=null===(s=this.internals)||void 0===s?void 0:s.form;i&&t.target===i&&(t.preventDefault(),this.submit())}seeded(t){return Object.assign(Object.assign({},o(this.effectiveSpec())),t)}effectiveSpec(){var t;return null!==(t=this.expandedSpec)&&void 0!==t?t:this.spec}async runExpansion(){if(this.expandError=void 0,this.editable||!n(this.spec))return void(this.expandedSpec=void 0);const t=this.spec;this.expanding=!0;try{const s=await c(t);this.spec===t&&(this.expandedSpec=s,this.currentData=this.seeded(this.currentData))}catch(s){this.spec===t&&(this.expandedSpec=void 0,this.expandError=s instanceof Error?s.message:String(s))}finally{this.spec===t&&(this.expanding=!1)}}publicData(){return Object.fromEntries(Object.entries(this.currentData).filter((([t])=>!t.startsWith("_"))))}dataMap(t=this.currentData){return this.context?Object.assign(Object.assign({},t),this.context):t}handleBrickDataChange(t){t.stopPropagation(),this.currentData=this.applyValueEffects(Object.assign(Object.assign({},this.currentData),t.detail));const s=Object.assign({},this.touched);for(const i of Object.keys(t.detail))s[i]=!0;this.touched=s;const{valid:i,errors:e}=this.runValidation();this.formDataChange.emit({data:this.publicData(),isValid:i,errors:e}),this.emitValidity({valid:i,errors:e})}applyValueEffects(t){var s,i;let e=t;for(const{brick:t}of h(this.effectiveSpec())){const r=null===(s=t.configs)||void 0===s?void 0:s.key;if(!r||!(null===(i=t.rules)||void 0===i?void 0:i.length))continue;const a=d(t.rules,this.dataMap(e));void 0!==a.value&&e[r]!==a.value&&(e=Object.assign(Object.assign({},e),{[r]:a.value}))}return e}async validate(){var t;const s={};for(const{brick:i}of h(this.effectiveSpec())){const e=null===(t=i.configs)||void 0===t?void 0:t.key;e&&(s[e]=!0)}this.touched=s;const i=this.runValidation(),e=Object.assign({},i.errors);let r=i.valid;const a=Array.from(this.host.querySelectorAll("fk-data-grid"));for(const t of a){const s=await t.validateRows();r=r&&s.valid,Object.assign(e,s.errors)}const o={valid:r,errors:e};return this.emitValidity(o),this.formDataChange.emit({data:this.publicData(),isValid:o.valid,errors:o.errors}),o}async submit(){const t=await this.validate();return!t.valid||this.readOnly||this.disabled||this.formSubmit.emit({data:this.publicData(),isValid:!0,errors:{}}),t}handleStepTouch(t){t.stopPropagation();const s=Object.assign({},this.touched);for(const i of t.detail.keys)s[i]=!0;this.touched=s}async handleStepperSubmit(t){t.stopPropagation(),await this.submit()}runValidation(){const t=Object.fromEntries(Object.entries(this.currentData).filter((([,t])=>""!==t&&null!=t)));return l(this.effectiveSpec(),t,this.locale,this.context?this.dataMap(t):void 0)}visibleErrors(){if(this.editable)return{};const t={};for(const[s,i]of Object.entries(this.runValidation().errors))this.touched[s]&&(t[s]=i);return t}render(){var t;return this.spec?this.expanding?r("p",{class:"fk-form__expanding"},a("nestedForm.loading")):r("form",{class:"fk-form",onSubmit:t=>t.preventDefault()},this.expandError?r("span",{class:"fk-field__error",role:"alert"},this.expandError):null,r("fk-brick-render",{brickSpec:this.effectiveSpec(),rootSpec:this.effectiveSpec(),data:this.currentData,dataMap:this.dataMap(),errors:this.visibleErrors(),locale:this.locale,path:"0",editable:this.editable,readOnly:this.readOnly,disabled:this.disabled,selectedPath:this.selectedPath,utils:this.utils}),!this.showSubmit||this.editable||this.readOnly||this.disabled?null:r("button",{type:"submit",class:"fk-form__submit",onClick:t=>{t.preventDefault(),this.submit()}},null!==(t=this.submitLabel)&&void 0!==t?t:a("form.submit"))):null}static get formAssociated(){return!0}get host(){return this}static get watchers(){return{data:[{syncData:0}],spec:[{onSpecChange:0}]}}static get style(){return".fk-form.sc-fk-form-render{display:flex;flex-direction:column;gap:var(--fk-spacing);font-family:var(--fk-font);color:var(--fk-color-text)}"}},[66,"fk-form-render",{spec:[16],data:[16],context:[16],editable:[4],readOnly:[4,"read-only"],disabled:[4],showSubmit:[4,"show-submit"],submitLabel:[1,"submit-label"],selectedPath:[1,"selected-path"],locale:[1],currentData:[32],touched:[32],expandedSpec:[32],expanding:[32],expandError:[32],validate:[64],submit:[64]},[[8,"submit","handleHostFormSubmit"],[0,"brickDataChange","handleBrickDataChange"],[0,"stepTouch","handleStepTouch"],[0,"stepperSubmit","handleStepperSubmit"]],{data:[{syncData:0}],spec:[{onSpecChange:0}]}]);function D(){"undefined"!=typeof customElements&&["fk-form-render","fk-brick-actions","fk-brick-not-found","fk-brick-render","fk-code-editor","fk-data-grid","fk-drop-area","fk-file-input","fk-select-input","fk-signature-input","fk-stepper","fk-tabs"].forEach((s=>{switch(s){case"fk-form-render":customElements.get(t(s))||customElements.define(t(s),E);break;case"fk-brick-actions":customElements.get(t(s))||m();break;case"fk-brick-not-found":customElements.get(t(s))||u();break;case"fk-brick-render":customElements.get(t(s))||p();break;case"fk-code-editor":customElements.get(t(s))||b();break;case"fk-data-grid":customElements.get(t(s))||k();break;case"fk-drop-area":customElements.get(t(s))||v();break;case"fk-file-input":customElements.get(t(s))||j();break;case"fk-select-input":customElements.get(t(s))||y();break;case"fk-signature-input":customElements.get(t(s))||g();break;case"fk-stepper":customElements.get(t(s))||O();break;case"fk-tabs":customElements.get(t(s))||S()}}))}D();export{E as F,D as d}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t,p as s,H as a,c as e,h as i}from"./p-B29HakDD.js";import{m as o,v as r}from"./p-BypSt35U.js";const n=s(class extends a{constructor(t){super(),!1!==t&&this.__registerHost(),this.stepTouch=e(this,"stepTouch"),this.tabLabels=[],this.editable=!1,this.active=0}clampActive(){this.active>Math.max(this.tabLabels.length-1,0)&&(this.active=0)}componentDidRender(){const t=this.host.querySelector(".fk-tabs__body");t&&Array.from(t.children).forEach(((t,s)=>{const a=t;this.editable?a.style.removeProperty("display"):a.style.display=s===this.active?"":"none"}))}validateTabs(){var t,s;return!0===(null===(s=null===(t=this.spec)||void 0===t?void 0:t.configs)||void 0===s?void 0:s.validateTabs)}tabSpec(t){var s,a,e;const i=null===(a=null===(s=this.spec)||void 0===s?void 0:s.children)||void 0===a?void 0:a[t];if(i&&this.spec)return(null===(e=this.tabCache)||void 0===e?void 0:e.source)!==this.spec&&(this.tabCache={source:this.spec,specs:[]}),this.tabCache.specs[t]||(this.tabCache.specs[t]={type:"panel",id:"tab",name:"Tab",configs:{key:`tab_${t}`},children:[i]}),this.tabCache.specs[t]}tabKeys(t){var s,a,e;const i=null===(a=null===(s=this.spec)||void 0===s?void 0:s.children)||void 0===a?void 0:a[t];if(!i)return[];const r=[];for(const t of o(i))(null===(e=t.configs)||void 0===e?void 0:e.key)&&r.push(t.configs.key);return r}tabValid(t){var s;const a=this.tabSpec(t);if(!a)return!0;const e=Object.fromEntries(Object.entries(null!==(s=this.dataMap)&&void 0!==s?s:{}).filter((([,t])=>""!==t&&null!=t)));return r(a,e,this.locale).valid}goToTab(t){t!==this.active&&(this.editable||!this.validateTabs()||this.tabValid(this.active)?this.active=t:this.stepTouch.emit({keys:this.tabKeys(this.active)}))}render(){return i("div",{key:"ebded73697ab12ae23d267ea30437129b10efffa",class:"fk-tabs"},i("div",{key:"b027f709c510a5ba1f2b38fdd20b7b131cf5888c",class:"fk-tabs__nav",role:"tablist"},this.tabLabels.map(((t,s)=>i("button",{key:`${s}-${t}`,type:"button",role:"tab","aria-selected":s===this.active?"true":"false",tabIndex:s===this.active?0:-1,class:{"fk-tabs__tab":!0,"fk-tabs__tab--active":s===this.active},onKeyDown:t=>{const a=this.tabLabels.length;!a||"ArrowRight"!==t.key&&"ArrowLeft"!==t.key||(t.preventDefault(),this.goToTab((s+("ArrowRight"===t.key?1:-1)+a)%a),requestAnimationFrame((()=>{var t;null===(t=this.host.querySelector(".fk-tabs__tab--active"))||void 0===t||t.focus()})))},onClick:t=>{t.preventDefault(),this.goToTab(s)}},t)))),i("div",{key:"ec7ed61a3f1f126268e2f1e0dfacfdb85dc542cd",class:"fk-tabs__body"},i("slot",{key:"4e86782cfe37f893992787265fdc764367672f67"})))}get host(){return this}static get watchers(){return{tabLabels:[{clampActive:0}]}}static get style(){return".sc-fk-tabs-h{display:block}.fk-tabs.sc-fk-tabs{display:flex;flex-direction:column;gap:var(--fk-spacing)}.fk-tabs__nav.sc-fk-tabs{display:flex;flex-wrap:wrap;gap:2px;border-bottom:1px solid var(--fk-color-border)}.fk-tabs__tab.sc-fk-tabs{font:inherit;font-size:0.85rem;font-weight:500;padding:calc(var(--fk-spacing) / 1.5) var(--fk-spacing);min-height:24px;border:none;border-bottom:2px solid transparent;border-radius:0;background:transparent;color:var(--fk-color-muted);text-transform:none;letter-spacing:normal;cursor:pointer}.fk-tabs__tab.sc-fk-tabs:hover{color:var(--fk-color-text)}.fk-tabs__tab--active.sc-fk-tabs{color:var(--fk-color-primary);border-bottom-color:var(--fk-color-primary);font-weight:600}"}},[262,"fk-tabs",{tabLabels:[16],editable:[4],spec:[16],dataMap:[16],locale:[1],active:[32]},void 0,{tabLabels:[{clampActive:0}]}]);function c(){"undefined"!=typeof customElements&&["fk-tabs"].forEach((s=>{"fk-tabs"===s&&(customElements.get(t(s))||customElements.define(t(s),n))}))}c();export{n as F,c as d}
|