@fewangsit/wangsvue-fats 1.0.0-alpha.15 → 1.0.0-alpha.151

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.
Files changed (169) hide show
  1. package/components/animation/Animation.vue.d.ts +9 -1
  2. package/components/assetinfo/AssetInfo.vue.d.ts +15 -16
  3. package/components/badgegroup/BadgeGroup.vue.d.ts +3 -1
  4. package/components/basetree/BaseTree.vue.d.ts +6 -1
  5. package/components/button/Button.vue.d.ts +3 -2
  6. package/components/buttonaddbyscan/ButtonAddByScan.vue.d.ts +40 -0
  7. package/components/buttonbulkaction/ButtonBulkAction.vue.d.ts +1 -0
  8. package/components/buttondownload/ButtonDownload.vue.d.ts +31 -0
  9. package/components/buttonradio/ButtonRadio.vue.d.ts +1 -0
  10. package/components/buttonscan/ButtonScan.vue.d.ts +3 -2
  11. package/components/buttonsearchbyscan/ButtonSearchByScan.vue.d.ts +46 -0
  12. package/components/buttonselecttree/ButtonSelectTree.vue.d.ts +2 -1
  13. package/components/buttonsplit/ButtonSplit.vue.d.ts +352 -34
  14. package/components/buttonsync/ButtonSync.vue.d.ts +13 -1
  15. package/components/buttontoggle/ButtonToggle.vue.d.ts +1 -0
  16. package/components/buttonviewlog/ButtonViewLog.vue.d.ts +17 -0
  17. package/components/calendar/Calendar.vue.d.ts +32 -4
  18. package/components/card/Card.vue.d.ts +1 -0
  19. package/components/carousel/Carousel.vue.d.ts +28 -0
  20. package/components/checkbox/Checkbox.vue.d.ts +1 -0
  21. package/components/datatable/DataTable.vue.d.ts +14 -4
  22. package/components/dialog/Dialog.vue.d.ts +4 -3
  23. package/components/dialogassetnamedetail/DialogAssetNameDetail.vue.d.ts +46 -0
  24. package/components/dialogassetnamedetail/options/columns.d.ts +2 -0
  25. package/components/dialogassetnamedetail/options/filter.d.ts +2 -0
  26. package/components/dialogconfirm/DialogConfirm.vue.d.ts +2 -1
  27. package/components/dialogform/DialogForm.vue.d.ts +3 -2
  28. package/components/dialoglinkedasset/DialogLinkedAsset.vue.d.ts +106 -0
  29. package/components/dialogprintqr/DialogPrintQR.vue.d.ts +18 -0
  30. package/components/dialogreportdamage/DialogReportDamage.vue.d.ts +34 -0
  31. package/components/dialogreportmissing/DialogReportMissing.vue.d.ts +33 -0
  32. package/components/dialogreporttag/DialogReportTag.vue.d.ts +31 -0
  33. package/components/dialogselecttree/DialogSelectTree.vue.d.ts +3 -2
  34. package/components/dialogselectuser/DialogSelectUser.vue.d.ts +102 -0
  35. package/components/dialogselectuser/options/columns.d.ts +3 -0
  36. package/components/dialogtransferlog/DialogTransferLog.vue.d.ts +16 -0
  37. package/components/dropdown/Dropdown.vue.d.ts +28 -4
  38. package/components/editor/Editor.vue.d.ts +1 -0
  39. package/components/fieldwrapper/FieldWrapper.vue.d.ts +19 -2
  40. package/components/fileupload/FileUpload.vue.d.ts +1 -0
  41. package/components/filtercontainer/FilterContainer.vue.d.ts +104 -69
  42. package/components/form/Form.vue.d.ts +4 -1
  43. package/components/icon/Icon.vue.d.ts +4 -0
  44. package/components/image/Image.vue.d.ts +8 -0
  45. package/components/imagecompressor/ImageCompressor.vue.d.ts +14 -0
  46. package/components/index.d.ts +34 -22
  47. package/components/inputcurrency/helpers/currency.helper.d.ts +5 -1
  48. package/components/inputemail/InputEmail.vue.d.ts +1 -0
  49. package/components/inputnumber/InputNumber.vue.d.ts +6 -0
  50. package/components/inputotp/InputOtp.vue.d.ts +3 -0
  51. package/components/inputpassword/InputPassword.vue.d.ts +1 -0
  52. package/components/inputrangenumber/InputRangeNumber.vue.d.ts +1 -0
  53. package/components/inputsearch/InputSearch.vue.d.ts +7 -1
  54. package/components/inputtext/InputText.vue.d.ts +2 -1
  55. package/components/inputurl/InputURL.vue.d.ts +4 -2
  56. package/components/invisiblefield/InvisibleField.vue.d.ts +32 -36
  57. package/components/languagedropdown/LanguageDropdown.vue.d.ts +5 -19
  58. package/components/litedropdown/LiteDropdown.vue.d.ts +5 -3
  59. package/components/loading/store/loading.store.d.ts +3 -3
  60. package/components/menu/Menu.vue.d.ts +2 -1
  61. package/components/multiselect/MultiSelect.vue.d.ts +7 -4
  62. package/components/overlaypanel/OverlayPanel.vue.d.ts +1 -0
  63. package/components/paginator/Paginator.vue.d.ts +285 -0
  64. package/components/steps/Steps.vue.d.ts +20 -0
  65. package/components/tabmenu/TabMenu.vue.d.ts +7 -191
  66. package/components/tagtype/TagType.vue.d.ts +5 -0
  67. package/components/textarea/Textarea.vue.d.ts +2 -1
  68. package/components/timeline/Timeline.vue.d.ts +21 -2
  69. package/components/toast/Toast.vue.d.ts +2 -1
  70. package/components/toggleswitch/ToggleSwitch.vue.d.ts +1 -0
  71. package/components/transactionroles/TransactionRoles.vue.d.ts +58 -0
  72. package/components/tree/Tree.vue.d.ts +6 -3
  73. package/components/tree/helpers/filterNodeKeys.helper.d.ts +8 -2
  74. package/components/tree/helpers/flattenTreeNodeChildren.helper.d.ts +3 -1
  75. package/components/ts-helpers.d.ts +8 -0
  76. package/components/username/UserName.vue.d.ts +6 -1
  77. package/components/userwithicon/UserWithIcon.vue.d.ts +2 -2
  78. package/config/defaultProps.d.ts +1 -1
  79. package/config/index.d.ts +1 -1
  80. package/config/locale.d.ts +1 -1
  81. package/directives/focus.d.ts +1 -1
  82. package/event-bus/index.d.ts +59 -53
  83. package/event-bus/mitt.d.ts +29 -14
  84. package/main.d.ts +34 -2
  85. package/package.json +16 -8
  86. package/plugins/VueHtmlToPaper.d.ts +11 -0
  87. package/plugins/WangsVue.d.ts +278 -98
  88. package/plugins/formValidation.d.ts +16 -6
  89. package/plugins/i18n-extension.d.ts +1 -1
  90. package/plugins/i18n.d.ts +90 -67
  91. package/stats.html +4949 -0
  92. package/style.css +1 -1
  93. package/utils/date.util.d.ts +64 -31
  94. package/utils/exportToExcel.util.d.ts +23 -16
  95. package/utils/formatTagCode.util.d.ts +1 -0
  96. package/utils/getStatusSeverity.util.d.ts +30 -0
  97. package/utils/index.d.ts +8 -21
  98. package/utils/isBasic.util.d.ts +1 -0
  99. package/utils/listenSidebarChanges.util.d.ts +14 -9
  100. package/utils/object.util.d.ts +14 -3
  101. package/utils/role.util.d.ts +63 -26
  102. package/utils/toast.util.d.ts +78 -78
  103. package/utils/xlsx.util.d.ts +19 -0
  104. package/wangsvue-fats.js +56981 -0
  105. package/wangsvue-fats.system.js +199 -281
  106. package/assets/json/currencies.json.d.ts +0 -1068
  107. package/assets/lottie/admin/loading-page.lottie +0 -0
  108. package/assets/lottie/admin/loading-table.lottie +0 -0
  109. package/assets/lottie/admin/no-data.lottie +0 -0
  110. package/assets/lottie/supplyasset/loading-page.lottie +0 -0
  111. package/assets/lottie/supplyasset/loading-table.lottie +0 -0
  112. package/assets/lottie/supplyasset/no-data.lottie +0 -0
  113. package/assets/lottie/workspace/loading-page.lottie +0 -0
  114. package/assets/lottie/workspace/loading-plane.lottie +0 -0
  115. package/assets/lottie/workspace/loading-table.lottie +0 -0
  116. package/assets/lottie/workspace/no-data.lottie +0 -0
  117. package/build-entry.d.ts +0 -14
  118. package/components/buttonscan/helpers/getErrorCode.helper.d.ts +0 -3
  119. package/components/buttonscan/helpers/index.d.ts +0 -1
  120. package/components/buttonscan/workers/scanner.worker.d.ts +0 -1
  121. package/components/buttonsplit/ButtonSplit.d.ts +0 -350
  122. package/components/calendar/BaseCalendar.vue.d.ts +0 -86
  123. package/components/codesnippet/CodeSnippet.vue.d.ts +0 -14
  124. package/components/customcolumn/ColumnList.vue.d.ts +0 -27
  125. package/components/customcolumn/helpers/setVisibilityColumn.helper.d.ts +0 -12
  126. package/components/datatable/MultiRow.vue.d.ts +0 -16
  127. package/components/datatable/helpers/adjustMenuPosition.helper.d.ts +0 -1
  128. package/components/datatable/helpers/filter.helper.d.ts +0 -28
  129. package/components/datatable/helpers/index.d.ts +0 -3
  130. package/components/datatable/helpers/readConfig.helper.d.ts +0 -2
  131. package/components/datatable/store/dataTable.store.d.ts +0 -22
  132. package/components/editor/CodeSnippetAdapter.vue.d.ts +0 -92
  133. package/components/editor/EditorButton.vue.d.ts +0 -15
  134. package/components/editor/MentionList.vue.d.ts +0 -35
  135. package/components/editor/MentionSection.vue.d.ts +0 -92
  136. package/components/editor/codeSnippetExtension.d.ts +0 -3
  137. package/components/editor/mentionSectionExtension.d.ts +0 -3
  138. package/components/editor/suggestion.d.ts +0 -2
  139. package/components/filtercontainer/helpers/applyFilter.helper.d.ts +0 -5
  140. package/components/filtercontainer/helpers/formatDateTimeRange.helper.d.ts +0 -7
  141. package/components/filtercontainer/helpers/getOption.helper.d.ts +0 -3
  142. package/components/gallerypreview/GalleryPreview.vue.d.ts +0 -31
  143. package/components/hardwaresync/store/device.store.d.ts +0 -36
  144. package/components/helpers/convertToArrayClass.helper.d.ts +0 -2
  145. package/components/helpers/index.d.ts +0 -2
  146. package/components/helpers/label.d.ts +0 -15
  147. package/components/imagecompressor/BackgroundImageCropper.vue.d.ts +0 -36
  148. package/components/imagecompressor/ImageInputInfo.vue.d.ts +0 -30
  149. package/components/inputgroup/InputGroup.vue.d.ts +0 -141
  150. package/components/inputphonenumber/helpers/getUserLocation.helper.d.ts +0 -8
  151. package/components/languagedropdown/LanguageDropdownOption.vue.d.ts +0 -18
  152. package/components/menu/helpers/filterMenu.helper.d.ts +0 -12
  153. package/components/menu/helpers/index.d.ts +0 -1
  154. package/components/menuitem/MenuItem.vue.d.ts +0 -19
  155. package/components/progressbar/ProgressBar.vue.d.ts +0 -72
  156. package/components/quickfilter/QuickFilter.vue.d.ts +0 -25
  157. package/components/timeline/TimelineContentByType.vue.d.ts +0 -16
  158. package/components/tooltipspan/TooltipSpan.vue.d.ts +0 -20
  159. package/components/tree/helpers/index.d.ts +0 -3
  160. package/components/usergroup/UserGroup.vue.d.ts +0 -57
  161. package/types/options.type.d.ts +0 -16
  162. package/utils/addAttachment.util.d.ts +0 -43
  163. package/utils/filterOptions.util.d.ts +0 -3
  164. package/utils/genPlaceholder.util.d.ts +0 -8
  165. package/utils/getAttachmentIcon.util.d.ts +0 -8
  166. package/utils/getSeverityByAssetStatus.util.d.ts +0 -3
  167. package/utils/mergePropsWithDefaults.util.d.ts +0 -20
  168. package/utils/textFormatter.util.d.ts +0 -17
  169. package/wangsvue-fats.es.js +0 -133778
@@ -1,4 +1,4 @@
1
- import { ClassComponent } from 'lib/components/ts-helpers.d';
1
+ import { ClassComponent } from '../../components/ts-helpers.d';
2
2
 
3
3
  export interface AnimationDefaultConfig {
4
4
  libPath: 'supplyasset' | 'workspace' | 'admin';
@@ -6,6 +6,14 @@ export interface AnimationDefaultConfig {
6
6
 
7
7
  export interface AnimationProps {
8
8
  animation: 'no-data' | 'loading-plane' | 'loading-page' | 'loading-table';
9
+ /**
10
+ * @default true
11
+ */
12
+ autoplay?: boolean;
13
+ /**
14
+ * @default true
15
+ */
16
+ loop?: boolean;
9
17
  }
10
18
 
11
19
  /**
@@ -1,5 +1,7 @@
1
- import { ClassComponent, GlobalComponentConstructor } from '../.././components/ts-helpers.d';
2
-
1
+ import {
2
+ ClassComponent,
3
+ GlobalComponentConstructor,
4
+ } from '../../components/ts-helpers.d';
3
5
 
4
6
  type Field = 'brand' | 'model' | 'group' | 'status';
5
7
 
@@ -15,23 +17,20 @@ export interface AssetInfoProps {
15
17
  * It will prevent dynamic fetch of asset information.
16
18
  */
17
19
  transactionDetail?: Record<string, unknown>;
20
+
21
+ /**
22
+ * @default true
23
+ */
24
+ useNfc?: boolean;
25
+
26
+ /**
27
+ * @default true
28
+ */
29
+ useTagType?: boolean;
18
30
  }
19
31
 
20
32
  declare class AssetInfo extends ClassComponent<
21
- {
22
- /**
23
- * Asset info title
24
- */
25
- title: string;
26
- /**
27
- * Asset info description
28
- */
29
- description: string;
30
- /**
31
- * Asset info icon
32
- */
33
- icon: string;
34
- },
33
+ AssetInfoProps,
35
34
  unknown,
36
35
  unknown
37
36
  > {}
@@ -1,5 +1,7 @@
1
1
  import { Slot } from 'vue';
2
- import { BadgeProps } from 'lib/components/badge/Badge.vue.d';
2
+
3
+ import { BadgeProps } from '../../components/badge/Badge.vue.d';
4
+
3
5
  import { ClassComponent, HintedString } from '../ts-helpers.d';
4
6
 
5
7
  export type ObjectBadge = {
@@ -8,7 +8,9 @@
8
8
  *
9
9
  */
10
10
  import { VNode } from 'vue';
11
+
11
12
  import { ComponentHooks } from '../basecomponent';
13
+ import { MenuItem } from '../menuitem';
12
14
  import { PassThroughOptions } from '../passthrough';
13
15
  import {
14
16
  ClassComponent,
@@ -16,7 +18,6 @@ import {
16
18
  HintedString,
17
19
  PassThrough,
18
20
  } from '../ts-helpers';
19
- import { MenuItem } from '../menuitem';
20
21
 
21
22
  export declare type TreePassThroughOptionType<T = any> =
22
23
  | TreePassThroughAttributes
@@ -350,6 +351,10 @@ export interface BaseTreeProps {
350
351
  * @defaultValue false
351
352
  */
352
353
  loading?: boolean | undefined;
354
+ /**
355
+ * Defines the group tree to showing disposable groups.
356
+ */
357
+ showDisposableGroups?: boolean;
353
358
  /**
354
359
  * Icon to display when tree is loading.
355
360
  * @deprecated since v3.27.0. Use 'loadingicon' slot.
@@ -1,9 +1,10 @@
1
+ import { TooltipOptions } from 'primevue/tooltip';
1
2
  import { ButtonHTMLAttributes, VNode } from 'vue';
3
+
2
4
  import { WangsIcons } from '../icon/Icon.vue.d';
3
- import { TooltipOptions } from 'primevue/tooltip';
4
5
  import {
5
- GlobalComponentConstructor,
6
6
  ClassComponent,
7
+ GlobalComponentConstructor,
7
8
  HintedString,
8
9
  } from '../ts-helpers';
9
10
 
@@ -0,0 +1,40 @@
1
+ import { Asset } from '@tagsamurai/fats-api-services/src/types/oldAssetService.type';
2
+
3
+ import { QueryParams } from '../../components/datatable/DataTable.vue.d';
4
+ import { ClassComponent } from '../../components/ts-helpers.d';
5
+
6
+ export type AssetWithOptionalTAG = Omit<Asset, 'qr' | 'rfid'> & {
7
+ qr?: string | boolean;
8
+ rfid?: string | boolean;
9
+ };
10
+
11
+ export type ScanPayload = {
12
+ type: 'RFID' | 'QR';
13
+ code: string;
14
+ device: string; // Serial Number
15
+ asset?: AssetWithOptionalTAG;
16
+ };
17
+
18
+ export type ButtonAddByScanEmits = {
19
+ 'update:modelValue': [assets: AssetWithOptionalTAG[]];
20
+ 'scan': [payload: ScanPayload];
21
+ };
22
+
23
+ export interface ButtonAddByScanProps {
24
+ /**
25
+ * Defines asset data that already in the table.
26
+ *
27
+ */
28
+ modelValue: AssetWithOptionalTAG[];
29
+ reportedDisposalAssets?: boolean;
30
+ noDisposalAssets?: boolean;
31
+ queryParams?: QueryParams;
32
+ }
33
+
34
+ declare class ButtonAddByScan extends ClassComponent<
35
+ ButtonAddByScanProps,
36
+ unknown,
37
+ ButtonAddByScanEmits
38
+ > {}
39
+
40
+ export default ButtonAddByScan;
@@ -1,4 +1,5 @@
1
1
  import { DefineComponent } from 'vue';
2
+
2
3
  import { MenuItem } from '../menuitem';
3
4
 
4
5
  export interface ButtonBulkActionLocaleConfig {
@@ -1,5 +1,23 @@
1
+ import { DataTableProps } from '../datatable/DataTable.vue.d';
1
2
  import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers.d';
2
3
 
4
+ export interface ButtonDownloadLocaleConfig {
5
+ /**
6
+ * Message to display on loading ovevrlay while downloading
7
+ */
8
+ downloadingMessage: string;
9
+
10
+ /**
11
+ * Text when booleanValue is true
12
+ */
13
+ trueText: string;
14
+
15
+ /**
16
+ * Text when booleanValue is false
17
+ */
18
+ falseText: string;
19
+ }
20
+
3
21
  export interface ButtonDownloadProps {
4
22
  fileName: string;
5
23
  /**
@@ -21,6 +39,19 @@ export interface ButtonDownloadProps {
21
39
  * Texts below table in downloaded excel
22
40
  */
23
41
  additionalTextBelowTable?: (string | string[])[];
42
+ /**
43
+ * If this props exist, download data from provided configs instead syncing with data tables
44
+ */
45
+ dataConfigs?: Pick<
46
+ DataTableProps,
47
+ 'columns' | 'fetchFunction' | 'data' | 'tableTitle'
48
+ >[];
49
+ /**
50
+ * Specify the error message download excel when tableConfigs is in use
51
+ *
52
+ * @example 'Error, failed to download {fileName}' - fileName will be replaced
53
+ */
54
+ excelToastErrorMessage?: string;
24
55
  }
25
56
 
26
57
  /**
@@ -1,4 +1,5 @@
1
1
  import { StyleValue } from 'vue';
2
+
2
3
  import { ComponentHooks } from '../basecomponent';
3
4
  import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
4
5
 
@@ -1,5 +1,6 @@
1
- import { ClassComponent, HintedString } from 'lib/components/ts-helpers.d';
2
- import { ButtonProps } from 'lib/components/button/Button.vue.d';
1
+ import { ButtonProps } from '../../components/button/Button.vue.d';
2
+ import { ClassComponent, HintedString } from '../../components/ts-helpers.d';
3
+
3
4
  import { WangsIcons } from '../icon/Icon.vue.d';
4
5
 
5
6
  export type ScannerErrorCode =
@@ -0,0 +1,46 @@
1
+ import { DefineComponent } from 'vue';
2
+
3
+ import { ButtonScanProps } from '../buttonscan/ButtonScan.vue.d';
4
+ import { WangsIcons } from '../icon/Icon.vue.d';
5
+
6
+ export type ScanPayload = {
7
+ type: 'RFID' | 'QR';
8
+ code: string;
9
+ device: string; // Serial Number
10
+ };
11
+
12
+ export type ButtonSearchByScanEmits = {
13
+ scan: [payload: ScanPayload];
14
+ };
15
+
16
+ export interface ButtonSearchByScanProps {
17
+ /**
18
+ * The button label.
19
+ *
20
+ * @default 'Search by Scan'
21
+ */
22
+ label?: string;
23
+ /**
24
+ * The button icon.
25
+ */
26
+ icon?: WangsIcons;
27
+ /**
28
+ * The datatable tablename which handles the search by scan.
29
+ *
30
+ * @default 'datatable' - default DataTable tablename
31
+ */
32
+ tableName?: string;
33
+ bulk?: boolean;
34
+ scanValidation?: ButtonScanProps['scanValidation'];
35
+ }
36
+
37
+ export type ButtonSearchByScanExposes = {
38
+ stopScan: (afterScan?: boolean) => void;
39
+ };
40
+
41
+ declare const ButtonSearchByScan: DefineComponent<
42
+ ButtonSearchByScanProps,
43
+ ButtonSearchByScanEmits
44
+ >;
45
+
46
+ export default ButtonSearchByScan;
@@ -1,7 +1,8 @@
1
1
  import { Slot } from 'vue';
2
- import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
2
+
3
3
  import { TreeNode } from '../basetree/BaseTree.vue.d';
4
4
  import { QueryParams, ShortFetchResponse } from '../datatable/DataTable.vue.d';
5
+ import { ClassComponent, GlobalComponentConstructor } from '../ts-helpers';
5
6
 
6
7
  export type KeysModelValue = number[] | undefined;
7
8
  export type NodeModelValue =
@@ -1,34 +1,352 @@
1
- import { ButtonSplitProps } from './ButtonSplit.d';
2
- declare function __VLS_template(): {
3
- menuitemicon?(_: {
4
- item: any;
5
- class: any;
6
- }): any;
7
- item?(_: {
8
- hasSubmenu: any;
9
- item: any;
10
- label: any;
11
- props: any;
12
- }): any;
13
- };
14
- declare const __VLS_component: import('vue').DefineComponent<__VLS_TypePropsToOption<ButtonSplitProps>, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
15
- click: (event: Event) => void;
16
- }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToOption<ButtonSplitProps>>> & {
17
- onClick?: (event: Event) => any;
18
- }, {}, {}>;
19
- declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
20
- export default _default;
21
- type __VLS_WithTemplateSlots<T, S> = T & {
22
- new (): {
23
- $slots: S;
24
- };
25
- };
26
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
27
- type __VLS_TypePropsToOption<T> = {
28
- [K in keyof T]-?: {} extends Pick<T, K> ? {
29
- type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
30
- } : {
31
- type: import('vue').PropType<T[K]>;
32
- required: true;
33
- };
34
- };
1
+ /**
2
+ *
3
+ * ButtonSplit groups a set of commands in an overlay with a default command.
4
+ *
5
+ * [Live Demo](https://www.primevue.org/splitbutton/)
6
+ *
7
+ * @module splitbutton
8
+ *
9
+ */
10
+ import { ButtonPassThroughOptions } from 'primevue/button';
11
+ import {
12
+ TieredMenuPassThroughOptions,
13
+ TieredMenuRouterBindProps,
14
+ } from 'primevue/tieredmenu';
15
+ import { ButtonHTMLAttributes, VNode } from 'vue';
16
+
17
+ import { ComponentHooks } from '../basecomponent';
18
+ import { MenuItem } from '../menuitem';
19
+ import { PassThroughOptions } from '../passthrough';
20
+ import {
21
+ ClassComponent,
22
+ GlobalComponentConstructor,
23
+ HintedString,
24
+ PassThrough,
25
+ } from '../ts-helpers';
26
+
27
+ import { WangsIcons } from '../icon/Icon.vue';
28
+
29
+ export declare type ButtonSplitPassThroughOptionType =
30
+ | ButtonSplitPassThroughAttributes
31
+ | ((
32
+ options: ButtonSplitPassThroughMethodOptions,
33
+ ) => ButtonSplitPassThroughAttributes | string)
34
+ | string
35
+ | null
36
+ | undefined;
37
+
38
+ /**
39
+ * Custom passthrough(pt) option method.
40
+ */
41
+ export interface ButtonSplitPassThroughMethodOptions {
42
+ /**
43
+ * Defines instance.
44
+ */
45
+ instance: any;
46
+ /**
47
+ * Defines valid properties.
48
+ */
49
+ props: ButtonSplitProps;
50
+ /**
51
+ * Defines current inline state.
52
+ */
53
+ state: ButtonSplitState;
54
+ /**
55
+ * Defines valid attributes.
56
+ */
57
+ attrs: any;
58
+ /**
59
+ * Defines parent options.
60
+ */
61
+ parent: any;
62
+ /**
63
+ * Defines passthrough(pt) options in global config.
64
+ */
65
+ global: object | undefined;
66
+ }
67
+
68
+ /**
69
+ * Custom shared passthrough(pt) option method.
70
+ */
71
+ export interface ButtonSplitSharedPassThroughMethodOptions {
72
+ /**
73
+ * Defines valid properties.
74
+ */
75
+ props: ButtonSplitProps;
76
+ /**
77
+ * Defines current inline state.
78
+ */
79
+ state: ButtonSplitState;
80
+ }
81
+
82
+ /**
83
+ * Custom passthrough(pt) options.
84
+ * @see {@link ButtonSplitProps.pt}
85
+ */
86
+ export interface ButtonSplitPassThroughOptions {
87
+ /**
88
+ * Used to pass attributes to the root's DOM element.
89
+ */
90
+ root?: ButtonSplitPassThroughOptionType;
91
+ /**
92
+ * Used to pass attributes to the button's DOM element.
93
+ */
94
+ button?: ButtonSplitPassThroughOptionType;
95
+ /**
96
+ * Used to pass attributes to the Button component.
97
+ * @see {@link ButtonPassThroughOptions}
98
+ */
99
+ menuButton?: ButtonPassThroughOptions<ButtonSplitSharedPassThroughMethodOptions>;
100
+ /**
101
+ * Used to pass attributes to the TieredMenu component.
102
+ * @see {@link TieredMenuPassThroughOptions}
103
+ */
104
+ menu?: TieredMenuPassThroughOptions<ButtonSplitSharedPassThroughMethodOptions>;
105
+ /**
106
+ * Used to manage all lifecycle hooks.
107
+ * @see {@link BaseComponent.ComponentHooks}
108
+ */
109
+ hooks?: ComponentHooks;
110
+ }
111
+
112
+ /**
113
+ * Custom passthrough attributes for each DOM elements
114
+ */
115
+ export interface ButtonSplitPassThroughAttributes {
116
+ [key: string]: any;
117
+ }
118
+
119
+ /**
120
+ * Defines current inline state in ButtonSplit component.
121
+ */
122
+ export interface ButtonSplitState {
123
+ /**
124
+ * Current blocked state as a boolean.
125
+ * @defaultValue false
126
+ */
127
+ isBlocked: boolean;
128
+ }
129
+
130
+ /**
131
+ * Defines valid properties in ButtonSplit component.
132
+ */
133
+ export interface ButtonSplitProps {
134
+ /**
135
+ * Text of the button.
136
+ */
137
+ label?: string | undefined;
138
+ /**
139
+ * Name of the icon of main button.
140
+ */
141
+ icon?: WangsIcons | undefined;
142
+ /**
143
+ * MenuModel instance to define the overlay items.
144
+ */
145
+ model?: MenuItem[] | undefined;
146
+ /**
147
+ * Whether to automatically manage layering.
148
+ * @defaultValue true
149
+ */
150
+ autoZIndex?: boolean | undefined;
151
+ /**
152
+ * Base zIndex value to use in layering.
153
+ * @defaultValue 0
154
+ */
155
+ baseZIndex?: number | undefined;
156
+ /**
157
+ * A valid query selector or an HTMLElement to specify where the overlay gets attached.
158
+ * Special keywords are 'body' for document body and 'self' for the element itself.
159
+ * @defaultValue body
160
+ */
161
+ appendTo?: HintedString<'body' | 'self'> | undefined | HTMLElement;
162
+ /**
163
+ * When present, it specifies that the element should be disabled.
164
+ * @defaultValue false
165
+ */
166
+ disabled?: boolean | undefined;
167
+ /**
168
+ * Style class of the component.
169
+ */
170
+ class?: any | undefined;
171
+ /**
172
+ * Inline style of the component.
173
+ */
174
+ style?: any | undefined;
175
+ /**
176
+ * Used to pass all properties of the HTMLButtonElement to the default button.
177
+ */
178
+ buttonProps?: ButtonHTMLAttributes | undefined;
179
+ /**
180
+ * Used to pass all properties of the HTMLButtonElement to the menu button.
181
+ */
182
+ menuButtonProps?: ButtonHTMLAttributes | undefined;
183
+ /**
184
+ * Name of the menu button icon.
185
+ */
186
+ menuButtonIcon?: WangsIcons | undefined;
187
+ /**
188
+ * Defines the style of the button.
189
+ */
190
+ severity?:
191
+ | HintedString<
192
+ | 'secondary'
193
+ | 'success'
194
+ | 'info'
195
+ | 'warning'
196
+ | 'help'
197
+ | 'danger'
198
+ | 'contrast'
199
+ >
200
+ | undefined;
201
+ /**
202
+ * Add a shadow to indicate elevation.
203
+ * @defaultValue false
204
+ */
205
+ raised?: boolean | undefined;
206
+ /**
207
+ * Add a circular border radius to the button.
208
+ * @defaultValue false
209
+ */
210
+ rounded?: boolean | undefined;
211
+ /**
212
+ * Add a textual class to the button without a background initially.
213
+ * @defaultValue false
214
+ */
215
+ text?: boolean | undefined;
216
+ /**
217
+ * Add a border class without a background initially.
218
+ * @defaultValue false
219
+ */
220
+ outlined?: boolean | undefined;
221
+ /**
222
+ * Defines the size of the button.
223
+ */
224
+ size?: 'small' | 'large' | undefined;
225
+ /**
226
+ * Add a plain textual class to the button without a background initially.
227
+ * @defaultValue false
228
+ */
229
+ plain?: boolean | undefined;
230
+ /**
231
+ * Used to pass attributes to DOM elements inside the component.
232
+ * @type {ButtonSplitPassThroughOptions}
233
+ */
234
+ pt?: PassThrough<ButtonSplitPassThroughOptions>;
235
+ /**
236
+ * Used to configure passthrough(pt) options of the component.
237
+ * @type {PassThroughOptions}
238
+ */
239
+ ptOptions?: PassThroughOptions;
240
+ /**
241
+ * When enabled, it removes component related styles in the core.
242
+ * @defaultValue false
243
+ */
244
+ unstyled?: boolean;
245
+ }
246
+
247
+ /**
248
+ * Defines valid slots in ButtonSplit component.
249
+ */
250
+ export interface ButtonSplitSlots {
251
+ /**
252
+ * Button part of the content can easily be customized with the default slot instead of using the built-in modes.
253
+ */
254
+ default(): VNode[];
255
+ /**
256
+ * Command button part of the content can easily be customized with the button content slot.
257
+ */
258
+ buttoncontent(): VNode[];
259
+ /**
260
+ * Custom button icon template.
261
+ * @param {Object} scope - icon slot's params.
262
+ */
263
+ icon(scope: {
264
+ /**
265
+ * Style class of the icon.
266
+ */
267
+ class: string;
268
+ }): VNode[];
269
+ /**
270
+ * Custom menu button icon template.
271
+ * @param {Object} scope - menubuttonicon slot's params.
272
+ */
273
+ menubuttonicon(scope: {
274
+ /**
275
+ * Style class of the icon.
276
+ */
277
+ class: string;
278
+ }): VNode[];
279
+ /**
280
+ * Custom menu item icon template.
281
+ * @param {Object} scope - menuitemicon slot's params.
282
+ */
283
+ menuitemicon(scope: {
284
+ /**
285
+ * Menuitem instance
286
+ */
287
+ item: MenuItem;
288
+ /**
289
+ * Style class of the item icon element.
290
+ */
291
+ class: any;
292
+ }): VNode[];
293
+ /**
294
+ * Custom content for each menu item.
295
+ * @param {Object} scope - item slot's params.
296
+ */
297
+ item(scope: {
298
+ /**
299
+ * Menuitem instance
300
+ */
301
+ item: MenuItem;
302
+ /**
303
+ * Label property of the menuitem
304
+ */
305
+ label: string | ((...args: any) => string) | undefined;
306
+ /**
307
+ * Binding properties of the menuitem
308
+ */
309
+ props: TieredMenuRouterBindProps;
310
+ /**
311
+ * Whether or not there is a submenu
312
+ */
313
+ hasSubmenu: boolean;
314
+ }): VNode[];
315
+ }
316
+
317
+ /**
318
+ * Defines valid emits in ButtonSplit component.
319
+ */
320
+ export interface ButtonSplitEmits {
321
+ /**
322
+ * Callback to invoke when main button is clicked.
323
+ * @param {Event} event - Browser event.
324
+ */
325
+ click(event: Event): void;
326
+ }
327
+
328
+ /**
329
+ * **PrimeVue - ButtonSplit**
330
+ *
331
+ * _ButtonSplit groups a set of commands in an overlay with a default command._
332
+ *
333
+ * [Live Demo](https://www.primevue.org/splitbutton/)
334
+ * --- ---
335
+ * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
336
+ *
337
+ * @group Component
338
+ *
339
+ */
340
+ declare class ButtonSplit extends ClassComponent<
341
+ ButtonSplitProps,
342
+ ButtonSplitSlots,
343
+ ButtonSplitEmits
344
+ > {}
345
+
346
+ declare module 'vue' {
347
+ export interface GlobalComponents {
348
+ ButtonSplit: GlobalComponentConstructor<ButtonSplit>;
349
+ }
350
+ }
351
+
352
+ export default ButtonSplit;
@@ -7,4 +7,16 @@ export interface ButtonSyncProps {
7
7
  withoutScanBtn?: boolean;
8
8
  }
9
9
 
10
- declare class ButtonSync extends ClassComponent<ButtonSyncProps> {}
10
+ declare class ButtonSync extends ClassComponent<
11
+ ButtonSyncProps,
12
+ unknown,
13
+ unknown
14
+ > {}
15
+
16
+ declare module 'vue' {
17
+ export interface GlobalComponents {
18
+ ButtonSync: typeof ButtonSync;
19
+ }
20
+ }
21
+
22
+ export default ButtonSync;
@@ -1,4 +1,5 @@
1
1
  import { DefineComponent } from 'vue';
2
+
2
3
  import {
3
4
  ToggleSwitchEmits,
4
5
  ToggleSwitchProps,