@ghentcdh/ui 1.1.1 → 3.0.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/ControlWrapper-DejmeYzV.js +1 -0
- package/ControlWrapper-DqO2d36v.js +152 -0
- package/Markdown-DcpBYoNe.js +1 -0
- package/Markdown-Dj1gzJJq.js +59 -0
- package/button/Btn.properties.d.ts +6 -2
- package/button/btn.vue.d.ts +15 -5
- package/const/colors.d.ts +2 -1
- package/drawer/drawer.properties.d.ts +4 -0
- package/drawer/drawer.vue.d.ts +9 -0
- package/filter/filter.vue.d.ts +1 -1
- package/form/Checkbox.properties.d.ts +14 -1
- package/form/Checkbox.vue.d.ts +41 -8
- package/form/Input.properties.d.ts +18 -1
- package/form/Input.vue.d.ts +50 -8
- package/form/InputNumber.properties.d.ts +14 -1
- package/form/InputNumber.vue.d.ts +41 -8
- package/form/Textarea.properties.d.ts +26 -1
- package/form/Textarea.vue.d.ts +68 -8
- package/form/core/ControlWrapper.properties.d.ts +54 -1
- package/form/core/ControlWrapper.vue.d.ts +42 -8
- package/form/core/properties.d.ts +2 -16
- package/form/core/styles.d.ts +1 -1
- package/form/core/utils/style.d.ts +3 -3
- package/form/index.d.ts +273 -1
- package/form/select/AutoComplete.properties.d.ts +27 -2
- package/form/select/AutoComplete.vue.d.ts +75 -15
- package/form/select/ListResults.properties.d.ts +7 -1
- package/form/select/ListResults.vue.d.ts +12 -3
- package/form/select/MultiSelect.vue.d.ts +73 -13
- package/form/select/SelectComponent.vue.d.ts +61 -10
- package/form/select/SelectWrapper.properties.d.ts +57 -9
- package/form/select/SelectWrapper.vue.d.ts +99 -17
- package/form/text/Markdown.vue.d.ts +41 -8
- package/form/text/MarkdownComponent.properties.d.ts +14 -1
- package/form/text/MarkdownFallback.vue.d.ts +267 -0
- package/icons/icon-list.d.ts +3 -1
- package/index.css +3 -1
- package/index.d.ts +1 -0
- package/index.js +2 -2
- package/index.mjs +2318 -2359
- package/modal/modal.vue.d.ts +1 -0
- package/package.json +26 -16
- package/table/cells/text.cell.vue.d.ts +1 -1
- package/table/column.model.d.ts +6 -0
- package/table/header/sort.header.properties.d.ts +1 -1
- package/table/header/sort.header.vue.d.ts +2 -2
- package/table/index.d.ts +2 -0
- package/table/pagination.component.properties.d.ts +5 -0
- package/table/pagination.component.vue.d.ts +9 -0
- package/table/table.component.properties.d.ts +4 -0
- package/table/table.component.vue.d.ts +9 -0
- package/table/table.model.d.ts +4 -1
- package/testing.js +1 -1
- package/testing.mjs +338 -419
- package/test-utils/withSetup.d.ts +0 -4
package/modal/modal.vue.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ghentcdh/ui",
|
|
3
3
|
"author": "GhentCDH",
|
|
4
|
-
"version": "
|
|
5
|
-
"
|
|
6
|
-
"
|
|
7
|
-
"module": "./index.js",
|
|
4
|
+
"version": "3.0.0",
|
|
5
|
+
"main": "./index.js",
|
|
6
|
+
"module": "./index.mjs",
|
|
8
7
|
"types": "./index.d.ts",
|
|
9
8
|
"exports": {
|
|
10
9
|
".": {
|
|
11
10
|
"types": "./index.d.ts",
|
|
12
|
-
"import": "./index.
|
|
13
|
-
"require": "./index.
|
|
11
|
+
"import": "./index.mjs",
|
|
12
|
+
"require": "./index.js"
|
|
14
13
|
},
|
|
15
14
|
"./testing": {
|
|
16
15
|
"types": "./testing/index.d.ts",
|
|
17
|
-
"import": "./testing.
|
|
18
|
-
"require": "./testing.
|
|
16
|
+
"import": "./testing.mjs",
|
|
17
|
+
"require": "./testing.js"
|
|
19
18
|
},
|
|
20
19
|
"./index.css": "./index.css",
|
|
21
20
|
"./package.json": "./package.json"
|
|
@@ -53,28 +52,39 @@
|
|
|
53
52
|
"peerDependenciesMeta": {
|
|
54
53
|
"@playwright/test": {
|
|
55
54
|
"optional": true
|
|
55
|
+
},
|
|
56
|
+
"@tiptap/pm": {
|
|
57
|
+
"optional": true
|
|
58
|
+
},
|
|
59
|
+
"@tiptap/starter-kit": {
|
|
60
|
+
"optional": true
|
|
61
|
+
},
|
|
62
|
+
"@tiptap/vue-3": {
|
|
63
|
+
"optional": true
|
|
64
|
+
},
|
|
65
|
+
"tiptap-markdown": {
|
|
66
|
+
"optional": true
|
|
56
67
|
}
|
|
57
68
|
},
|
|
58
69
|
"sideEffects": false,
|
|
59
|
-
"
|
|
60
|
-
"@
|
|
70
|
+
"peerDependencies": {
|
|
71
|
+
"@ghentcdh/json-forms-core": ">=0.0.1",
|
|
72
|
+
"@playwright/test": ">=1.50.0",
|
|
61
73
|
"@tiptap/pm": "^3.0.0",
|
|
62
74
|
"@tiptap/starter-kit": "^3.0.0",
|
|
63
75
|
"@tiptap/vue-3": "^3.0.0",
|
|
64
76
|
"tiptap-markdown": "^0.9.0",
|
|
65
|
-
"uuid": "^11.0.0"
|
|
66
|
-
},
|
|
67
|
-
"peerDependencies": {
|
|
68
|
-
"@ghentcdh/json-forms-core": ">=0.0.1",
|
|
69
|
-
"@ghentcdh/tools-vue": ">=0.6.0",
|
|
70
|
-
"@playwright/test": ">=1.50.0",
|
|
71
77
|
"vue": "^3.5.0",
|
|
72
78
|
"vue-router": "^5.0.0"
|
|
73
79
|
},
|
|
74
80
|
"devDependencies": {
|
|
75
81
|
"@tailwindcss/postcss": "4.2.1",
|
|
82
|
+
"@tiptap/pm": "3.20.0",
|
|
83
|
+
"@tiptap/starter-kit": "3.20.0",
|
|
84
|
+
"@tiptap/vue-3": "3.20.0",
|
|
76
85
|
"daisyui": "5.5.19",
|
|
77
86
|
"tailwindcss": "4.2.1",
|
|
87
|
+
"tiptap-markdown": "0.9.0",
|
|
78
88
|
"vue": "3.5.29",
|
|
79
89
|
"vue-router": "5.0.3"
|
|
80
90
|
},
|
|
@@ -22,5 +22,5 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
22
22
|
options: {
|
|
23
23
|
type: ObjectConstructor;
|
|
24
24
|
};
|
|
25
|
-
}>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {},
|
|
25
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
26
26
|
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
2
2
|
column: {
|
|
3
|
-
type: import('vue').PropType<import('
|
|
3
|
+
type: import('vue').PropType<import('..').ColumnDef>;
|
|
4
4
|
required: true;
|
|
5
5
|
};
|
|
6
6
|
sortColumn: {
|
|
@@ -11,7 +11,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
11
11
|
};
|
|
12
12
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
13
13
|
column: {
|
|
14
|
-
type: import('vue').PropType<import('
|
|
14
|
+
type: import('vue').PropType<import('..').ColumnDef>;
|
|
15
15
|
required: true;
|
|
16
16
|
};
|
|
17
17
|
sortColumn: {
|
package/table/index.d.ts
CHANGED
|
@@ -6,4 +6,6 @@ export { default as TableComponent } from './table.component.vue';
|
|
|
6
6
|
export { default as Table } from './table.component.vue';
|
|
7
7
|
export { default as TextCell } from './cells/text.cell.vue';
|
|
8
8
|
export { default as BooleanCell } from './cells/boolean.cell.vue';
|
|
9
|
+
export * from './column.model';
|
|
9
10
|
export * from './table.model';
|
|
11
|
+
export { type TablePage, type TableSort } from './table.component.properties';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { PropType } from 'vue';
|
|
1
2
|
export declare const PaginationComponentProperties: {
|
|
2
3
|
totalItems: {
|
|
3
4
|
type: NumberConstructor;
|
|
@@ -11,5 +12,9 @@ export declare const PaginationComponentProperties: {
|
|
|
11
12
|
type: NumberConstructor;
|
|
12
13
|
default: number;
|
|
13
14
|
};
|
|
15
|
+
pageSizeOptions: {
|
|
16
|
+
type: PropType<number[]>;
|
|
17
|
+
default: () => number[];
|
|
18
|
+
};
|
|
14
19
|
};
|
|
15
20
|
export declare const PaginationComponentEmits: string[];
|
|
@@ -11,6 +11,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
11
11
|
type: NumberConstructor;
|
|
12
12
|
default: number;
|
|
13
13
|
};
|
|
14
|
+
pageSizeOptions: {
|
|
15
|
+
type: import('vue').PropType<number[]>;
|
|
16
|
+
default: () => number[];
|
|
17
|
+
};
|
|
14
18
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
15
19
|
totalItems: {
|
|
16
20
|
type: NumberConstructor;
|
|
@@ -24,9 +28,14 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
24
28
|
type: NumberConstructor;
|
|
25
29
|
default: number;
|
|
26
30
|
};
|
|
31
|
+
pageSizeOptions: {
|
|
32
|
+
type: import('vue').PropType<number[]>;
|
|
33
|
+
default: () => number[];
|
|
34
|
+
};
|
|
27
35
|
}>> & Readonly<{}>, {
|
|
28
36
|
currentPage: number;
|
|
29
37
|
totalItems: number;
|
|
30
38
|
itemsPerPage: number;
|
|
39
|
+
pageSizeOptions: number[];
|
|
31
40
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
32
41
|
export default _default;
|
|
@@ -3,6 +3,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
3
3
|
type: BooleanConstructor;
|
|
4
4
|
default: false;
|
|
5
5
|
};
|
|
6
|
+
multiselect: {
|
|
7
|
+
type: BooleanConstructor;
|
|
8
|
+
default: false;
|
|
9
|
+
};
|
|
6
10
|
actions: {
|
|
7
11
|
type: import('vue').PropType<import('./table.model').TableAction[]>;
|
|
8
12
|
};
|
|
@@ -24,6 +28,10 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
24
28
|
type: BooleanConstructor;
|
|
25
29
|
default: false;
|
|
26
30
|
};
|
|
31
|
+
multiselect: {
|
|
32
|
+
type: BooleanConstructor;
|
|
33
|
+
default: false;
|
|
34
|
+
};
|
|
27
35
|
actions: {
|
|
28
36
|
type: import('vue').PropType<import('./table.model').TableAction[]>;
|
|
29
37
|
};
|
|
@@ -42,5 +50,6 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
42
50
|
};
|
|
43
51
|
}>> & Readonly<{}>, {
|
|
44
52
|
loading: boolean;
|
|
53
|
+
multiselect: boolean;
|
|
45
54
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
46
55
|
export default _default;
|
package/table/table.model.d.ts
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
|
-
import { ColumnDef } from '
|
|
1
|
+
import { ColumnDef } from './column.model';
|
|
2
2
|
import { IconEnum } from '../icons';
|
|
3
3
|
export type TableAction = {
|
|
4
4
|
label?: string;
|
|
5
|
+
tooltip?: string;
|
|
5
6
|
icon?: IconEnum;
|
|
6
7
|
action: <T>(data: T) => void;
|
|
8
|
+
/** Optional predicate — when provided, the button is only shown if this returns true for the row. */
|
|
9
|
+
visible?: <T>(data: T) => boolean;
|
|
7
10
|
};
|
|
8
11
|
export type DisplayColumn = ColumnDef & {
|
|
9
12
|
component: any;
|
package/testing.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=class{constructor(e){this.locator=e}page(){return this.locator.page()}asLocator(){return this.locator}},t=(e,t,n)=>e.getByRole(t,{name:n}),n=class n extends e{static byId(e,r){return new n(t(e,`textbox`,r))}static byLabel(e,r){return new n(t(e,`textbox`,r))}static for(e){return new n(e)}async fill(e){return await this.locator.click(),await this.locator.fill(e),this}async type(e){return await this.locator.click(),await this.locator.pressSequentially(e),this}async clear(){return await this.locator.fill(``),this}async value(){return this.locator.inputValue()}async blur(){return await this.locator.press(`Tab`),this}},r=class n extends e{static byId(e,r){return new n(t(e,`spinbutton`,r))}static byLabel(e,r){return new n(t(e,`spinbutton`,r))}static for(e){return new n(e)}async fill(e){return await this.locator.click(),await this.locator.fill(String(e)),await this.locator.press(`Tab`),this}async clear(){return await this.locator.fill(``),this}async value(){let e=await this.locator.inputValue();return e===``?null:Number(e)}},i=class n extends e{static byId(e,r){return new n(t(e,`textbox`,r))}static byLabel(e,r){return new n(t(e,`textbox`,r))}static for(e){return new n(e)}async fill(e){return await this.locator.click(),await this.locator.fill(e),this}async clear(){return await this.locator.fill(``),this}async value(){return this.locator.inputValue()}},a=class n extends e{static byId(e,r){return new n(t(e,`checkbox`,r))}static byLabel(e,r){return new n(t(e,`checkbox`,r))}static for(e){return new n(e)}async fill(e){return e?await this.locator.check():await this.locator.uncheck(),this}async toggle(){return await this.locator.click(),this}async value(){return this.locator.isChecked()}},o=class n extends e{static byId(e,r){return new n(t(e,`combobox`,r))}static byLabel(e,r){return new n(t(e,`combobox`,r))}static for(e){return new n(e)}async open(){return await this.locator.click(),this}async fill(e){return this.select(e)}async select(e){return await this.open(),await this.page().getByRole(`option`,{name:e}).locator(`a`).click(),this}async value(){return(await this.locator.textContent())?.trim()??``}async clear(){return await this.locator.locator(`xpath=ancestor::*[@role="select"][1]`).getByRole(`button`,{name:`Clear`}).click(),this}async clickCreateNew(){await this.locator.locator(`xpath=ancestor::*[@role="select"][1]`).getByRole(`button`,{name:`create`}).click()}},s=class n extends e{static byId(e,r){return new n(t(e,`combobox`,r))}static byLabel(e,r){return new n(t(e,`combobox`,r))}static for(e){return new n(e)}async fill(e){return await this.locator.click(),await this.locator.fill(e),await this.page().getByRole(`option`,{name:e}).locator(`a`).click(),this}async query(e){return await this.locator.click(),await this.locator.fill(e),this}async pickOption(e){return await this.page().getByRole(`option`,{name:e}).locator(`a`).click(),this}async press(e){return await this.locator.press(e),this}async clickCreateNew(){await this.locator.locator(`xpath=ancestor::*[@role="select"][1]`).getByRole(`button`,{name:`create`}).click()}async clear(){return await this.locator.locator(`xpath=ancestor::*[@role="select"][1]`).getByRole(`button`,{name:`Clear`}).click(),this}async value(){return this.locator.inputValue()}listbox(){return this.page().getByRole(`listbox`)}options(){return this.page().getByRole(`option`)}},c=class n extends e{static byId(e,r){return new n(t(e,`combobox`,r))}static byLabel(e,r){return new n(t(e,`combobox`,r))}static for(e){return new n(e)}async open(){return await this.locator.click(),this}async fill(e){await this.open();for(let t of e)await this.page().getByRole(`option`,{name:t}).locator(`a`).click();return await this.locator.click(),this}async select(e){return await this.open(),await this.page().getByRole(`option`,{name:e}).locator(`a`).click(),this}async removeChip(e){return await this.locator.locator(`xpath=ancestor::*[@role="select"][1]`).getByText(e,{exact:!0}).getByRole(`button`).click(),this}},l=class n extends e{static byId(e,r){return new n(t(e,`textbox`,r))}static byLabel(e,r){return new n(t(e,`textbox`,r))}static for(e){return new n(e)}get editor(){return this.locator.getByRole(`textbox`)}async fill(e){return await this.editor.fill(e),this}async clear(){return await this.editor.fill(``),this}async typeBold(e){return await this.toolbar(`B`).click(),await this.editor.pressSequentially(e),await this.toolbar(`B`).click(),this}async typeItalic(e){return await this.toolbar(`I`).click(),await this.editor.pressSequentially(e),await this.toolbar(`I`).click(),this}async type(e){return await this.editor.pressSequentially(e),this}toolbar(e){return this.locator.getByRole(`button`,{name:e})}async isMarkActive(e){return(await this.toolbar(e).getAttribute(`class`)??``).includes(`btn-active`)}},u=class t extends e{static byTitle(e,n){return new t(e.getByRole(`dialog`,{name:n}))}static current(e){return new t(e.getByRole(`dialog`))}static for(e){return new t(e)}async clickClose(){return await this.locator.getByRole(`button`,{name:`Close`}).click(),this}async pressEscape(){return await this.locator.press(`Escape`),this}async clickBackdrop(){return await this.locator.click({position:{x:5,y:5}}),this}async clickAction(e){return await this.locator.getByRole(`button`,{name:e}).click(),this}title(){return this.locator.locator(`h3`).first()}content(){return this.locator.locator(`[id$="_content"]`).first()}asLocator(){return this.locator}},d=class n extends e{static byName(e,r){return new n(t(e,`button`,r))}static for(e){return new n(e)}async click(){return await this.locator.click(),this}async isDisabled(){return this.locator.isDisabled()}async text(){return await this.locator.textContent()??``}},f=class t extends e{static byTitle(e,n){return new t(e.getByLabel(`Toggle ${n}`).locator(`..`))}static for(e){return new t(e)}async toggle(){return await this.checkbox().click(),this}async isOpen(){return this.checkbox().isChecked()}title(){return this.locator.locator(`.collapse-title span`).first()}content(){return this.locator.locator(`.collapse-content`)}checkbox(){return this.locator.locator(`input[type="checkbox"]`)}},p=class t extends e{static byMessage(e,n){return new t(e.getByRole(`alert`).filter({hasText:n}))}static first(e){return new t(e.getByRole(`alert`).first())}static for(e){return new t(e)}async message(){return await this.locator.locator(`span`).textContent()??``}async hasClass(e){return(await this.locator.getAttribute(`class`)??``).includes(e)}},m=class t extends e{static root(e){return new t(e.locator(`main`).first())}static for(e){return new t(e)}async toggleLeft(){return await this.leftButton().click(),this}async toggleRight(){return await this.rightButton().click(),this}async isLeftOpen(){return await this.leftButton().getAttribute(`aria-expanded`)===`true`}async isRightOpen(){return await this.rightButton().getAttribute(`aria-expanded`)===`true`}leftPanel(){return this.locator.locator(`#drawer-left-panel`)}rightPanel(){return this.locator.locator(`#drawer-right-panel`)}leftButton(){return this.locator.locator(`button[aria-controls="drawer-left-panel"]`)}rightButton(){return this.locator.locator(`button[aria-controls="drawer-right-panel"]`)}};exports.AlertHarness=p,exports.AutocompleteHarness=s,exports.BooleanHarness=a,exports.ButtonHarness=d,exports.CollapseHarness=f,exports.DrawerHarness=m,exports.Harness=e,exports.MarkdownHarness=l,exports.ModalHarness=u,exports.MultiSelectHarness=c,exports.NumberHarness=r,exports.SelectHarness=o,exports.TextAreaHarness=i,exports.TextHarness=n,exports.byRole=t;
|