@mikezimm/fps-library-v2 1.0.31 → 1.0.33

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 (131) hide show
  1. package/CHANGELOG.md +13 -1
  2. package/lib/banner/FPSWebPartClass/BuildBannerPropsX2.js +1 -1
  3. package/lib/banner/FPSWebPartClass/BuildBannerPropsX2.js.map +1 -1
  4. package/lib/banner/FPSWebPartClass/runOnPropChange.d.ts.map +1 -1
  5. package/lib/banner/FPSWebPartClass/runOnPropChange.js +25 -0
  6. package/lib/banner/FPSWebPartClass/runOnPropChange.js.map +1 -1
  7. package/lib/banner/components/EasyPages/functions.d.ts +1 -1
  8. package/lib/banner/components/EasyPages/functions.d.ts.map +1 -1
  9. package/lib/banner/components/SpecialBanner/component.d.ts +1 -1
  10. package/lib/banner/components/SpecialBanner/component.d.ts.map +1 -1
  11. package/lib/banner/features/Expando/functions.d.ts +1 -1
  12. package/lib/banner/features/Expando/functions.d.ts.map +1 -1
  13. package/lib/banner/features/FPSDOM/FPSEnviro.js +2 -2
  14. package/lib/banner/features/FPSDOM/FPSEnviro.js.map +1 -1
  15. package/lib/banner/features/PageStyle/minimzeToolbar.d.ts +2 -2
  16. package/lib/banner/features/PageStyle/minimzeToolbar.d.ts.map +1 -1
  17. package/lib/banner/features/PageStyle/setAllSectionStyles.d.ts +1 -1
  18. package/lib/banner/features/PageStyle/setAllSectionStyles.d.ts.map +1 -1
  19. package/lib/banner/features/PinMe/FPSPinMenu.d.ts +1 -1
  20. package/lib/banner/features/PinMe/FPSPinMenu.d.ts.map +1 -1
  21. package/lib/banner/mainReact/IWebpartBannerProps.d.ts +1 -1
  22. package/lib/banner/mainReact/IWebpartBannerProps.d.ts.map +1 -1
  23. package/lib/banner/propPane/controls.d.ts +1 -1
  24. package/lib/banner/propPane/controls.d.ts.map +1 -1
  25. package/lib/common/interfaces/openSource/spfxControlsReact/@3.7.2/IViewField.d.ts +139 -0
  26. package/lib/common/interfaces/openSource/spfxControlsReact/@3.7.2/IViewField.d.ts.map +1 -0
  27. package/lib/common/interfaces/openSource/spfxControlsReact/@3.7.2/IViewField.js +2 -0
  28. package/lib/common/interfaces/openSource/spfxControlsReact/@3.7.2/IViewField.js.map +1 -0
  29. package/lib/components/atoms/Elements/basic.d.ts +1 -1
  30. package/lib/components/atoms/Elements/basic.d.ts.map +1 -1
  31. package/lib/components/molecules/Accordion/Accordion.d.ts +24 -0
  32. package/lib/components/molecules/Accordion/Accordion.d.ts.map +1 -0
  33. package/lib/components/molecules/Accordion/Accordion.js +55 -0
  34. package/lib/components/molecules/Accordion/Accordion.js.map +1 -0
  35. package/lib/components/molecules/Arrows/PageArrows.d.ts +44 -0
  36. package/lib/components/molecules/Arrows/PageArrows.d.ts.map +1 -0
  37. package/lib/components/molecules/Arrows/PageArrows.js +134 -0
  38. package/lib/components/molecules/Arrows/PageArrows.js.map +1 -0
  39. package/lib/components/molecules/Performance/tables.d.ts +1 -1
  40. package/lib/components/molecules/Performance/tables.d.ts.map +1 -1
  41. package/lib/components/molecules/PropPaneCols/PropPaneCols.module.scss.d.ts +3 -0
  42. package/lib/components/molecules/PropPaneCols/PropPaneCols.module.scss.d.ts.map +1 -0
  43. package/lib/components/molecules/PropPaneCols/PropPaneCols.module.scss.js +6 -0
  44. package/lib/components/molecules/PropPaneCols/PropPaneCols.module.scss.js.map +1 -0
  45. package/lib/components/molecules/PropPaneCols/PropPaneColsClass.d.ts +42 -0
  46. package/lib/components/molecules/PropPaneCols/PropPaneColsClass.d.ts.map +1 -0
  47. package/lib/components/molecules/PropPaneCols/PropPaneColsClass.js +240 -0
  48. package/lib/components/molecules/PropPaneCols/PropPaneColsClass.js.map +1 -0
  49. package/lib/components/molecules/PropPaneCols/PropPaneColsHook.d.ts +1 -0
  50. package/lib/components/molecules/PropPaneCols/PropPaneColsHook.d.ts.map +1 -0
  51. package/lib/components/molecules/PropPaneCols/PropPaneColsHook.js +135 -0
  52. package/lib/components/molecules/PropPaneCols/PropPaneColsHook.js.map +1 -0
  53. package/lib/components/molecules/PropPaneCols/components/FieldPanel.d.ts +10 -0
  54. package/lib/components/molecules/PropPaneCols/components/FieldPanel.d.ts.map +1 -0
  55. package/lib/components/molecules/PropPaneCols/components/FieldPanel.js +43 -0
  56. package/lib/components/molecules/PropPaneCols/components/FieldPanel.js.map +1 -0
  57. package/lib/components/molecules/PropPaneCols/components/IPropPaneColsProps.d.ts +87 -0
  58. package/lib/components/molecules/PropPaneCols/components/IPropPaneColsProps.d.ts.map +1 -0
  59. package/lib/components/molecules/PropPaneCols/components/IPropPaneColsProps.js +2 -0
  60. package/lib/components/molecules/PropPaneCols/components/IPropPaneColsProps.js.map +1 -0
  61. package/lib/components/molecules/PropPaneCols/components/OnClickHelpers.d.ts +18 -0
  62. package/lib/components/molecules/PropPaneCols/components/OnClickHelpers.d.ts.map +1 -0
  63. package/lib/components/molecules/PropPaneCols/components/OnClickHelpers.js +120 -0
  64. package/lib/components/molecules/PropPaneCols/components/OnClickHelpers.js.map +1 -0
  65. package/lib/components/molecules/PropPaneCols/components/command/Accordion.d.ts +17 -0
  66. package/lib/components/molecules/PropPaneCols/components/command/Accordion.d.ts.map +1 -0
  67. package/lib/components/molecules/PropPaneCols/components/command/Accordion.js +229 -0
  68. package/lib/components/molecules/PropPaneCols/components/command/Accordion.js.map +1 -0
  69. package/lib/components/molecules/PropPaneCols/components/command/IAccordion.d.ts +69 -0
  70. package/lib/components/molecules/PropPaneCols/components/command/IAccordion.d.ts.map +1 -0
  71. package/lib/components/molecules/PropPaneCols/components/command/IAccordion.js +73 -0
  72. package/lib/components/molecules/PropPaneCols/components/command/IAccordion.js.map +1 -0
  73. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign copy.d.ts +9 -0
  74. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign copy.d.ts.map +1 -0
  75. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign copy.js +61 -0
  76. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign copy.js.map +1 -0
  77. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign.d.ts +10 -0
  78. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign.d.ts.map +1 -0
  79. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign.js +66 -0
  80. package/lib/components/molecules/PropPaneCols/components/command/SampleDesign.js.map +1 -0
  81. package/lib/components/molecules/PropPaneCols/components/command/createLogic.d.ts +13 -0
  82. package/lib/components/molecules/PropPaneCols/components/command/createLogic.d.ts.map +1 -0
  83. package/lib/components/molecules/PropPaneCols/components/command/createLogic.js +397 -0
  84. package/lib/components/molecules/PropPaneCols/components/command/createLogic.js.map +1 -0
  85. package/lib/components/molecules/PropPaneCols/components/command/helpers.d.ts +2 -0
  86. package/lib/components/molecules/PropPaneCols/components/command/helpers.d.ts.map +1 -0
  87. package/lib/components/molecules/PropPaneCols/components/command/helpers.js +2 -0
  88. package/lib/components/molecules/PropPaneCols/components/command/helpers.js.map +1 -0
  89. package/lib/components/molecules/PropPaneCols/components/command/tableRows.d.ts +5 -0
  90. package/lib/components/molecules/PropPaneCols/components/command/tableRows.d.ts.map +1 -0
  91. package/lib/components/molecules/PropPaneCols/components/command/tableRows.js +25 -0
  92. package/lib/components/molecules/PropPaneCols/components/command/tableRows.js.map +1 -0
  93. package/lib/components/molecules/PropPaneCols/components/common.d.ts +4 -0
  94. package/lib/components/molecules/PropPaneCols/components/common.d.ts.map +1 -0
  95. package/lib/components/molecules/PropPaneCols/components/common.js +16 -0
  96. package/lib/components/molecules/PropPaneCols/components/common.js.map +1 -0
  97. package/lib/components/molecules/PropPaneCols/components/fetch/Pane.d.ts +11 -0
  98. package/lib/components/molecules/PropPaneCols/components/fetch/Pane.d.ts.map +1 -0
  99. package/lib/components/molecules/PropPaneCols/components/fetch/Pane.js +51 -0
  100. package/lib/components/molecules/PropPaneCols/components/fetch/Pane.js.map +1 -0
  101. package/lib/components/molecules/PropPaneCols/components/fetch/funcions.d.ts +3 -0
  102. package/lib/components/molecules/PropPaneCols/components/fetch/funcions.d.ts.map +1 -0
  103. package/lib/components/molecules/PropPaneCols/components/fetch/funcions.js +96 -0
  104. package/lib/components/molecules/PropPaneCols/components/fetch/funcions.js.map +1 -0
  105. package/lib/components/molecules/PropPaneCols/components/main/FieldTable.d.ts +14 -0
  106. package/lib/components/molecules/PropPaneCols/components/main/FieldTable.d.ts.map +1 -0
  107. package/lib/components/molecules/PropPaneCols/components/main/FieldTable.js +68 -0
  108. package/lib/components/molecules/PropPaneCols/components/main/FieldTable.js.map +1 -0
  109. package/lib/components/molecules/PropPaneCols/components/main/Pane.d.ts +13 -0
  110. package/lib/components/molecules/PropPaneCols/components/main/Pane.d.ts.map +1 -0
  111. package/lib/components/molecules/PropPaneCols/components/main/Pane.js +87 -0
  112. package/lib/components/molecules/PropPaneCols/components/main/Pane.js.map +1 -0
  113. package/lib/components/molecules/PropPaneCols/components/selected/TableHook.d.ts +9 -0
  114. package/lib/components/molecules/PropPaneCols/components/selected/TableHook.d.ts.map +1 -0
  115. package/lib/components/molecules/PropPaneCols/components/selected/TableHook.js +63 -0
  116. package/lib/components/molecules/PropPaneCols/components/selected/TableHook.js.map +1 -0
  117. package/lib/components/molecules/PropPaneCols/components/selected/functions.d.ts +5 -0
  118. package/lib/components/molecules/PropPaneCols/components/selected/functions.d.ts.map +1 -0
  119. package/lib/components/molecules/PropPaneCols/components/selected/functions.js +59 -0
  120. package/lib/components/molecules/PropPaneCols/components/selected/functions.js.map +1 -0
  121. package/lib/components/molecules/PropPaneCols/components/views/Accordion.d.ts +12 -0
  122. package/lib/components/molecules/PropPaneCols/components/views/Accordion.d.ts.map +1 -0
  123. package/lib/components/molecules/PropPaneCols/components/views/Accordion.js +29 -0
  124. package/lib/components/molecules/PropPaneCols/components/views/Accordion.js.map +1 -0
  125. package/lib/components/molecules/PropPaneCols/components/views/functions.d.ts +5 -0
  126. package/lib/components/molecules/PropPaneCols/components/views/functions.d.ts.map +1 -0
  127. package/lib/components/molecules/PropPaneCols/components/views/functions.js +133 -0
  128. package/lib/components/molecules/PropPaneCols/components/views/functions.js.map +1 -0
  129. package/lib/logic/Errors/friendly.d.ts +1 -1
  130. package/lib/logic/Errors/friendly.d.ts.map +1 -1
  131. package/package.json +1 -1
@@ -0,0 +1,69 @@
1
+ import { IQuickButton, IQuickCommands, IQuickField } from "../../../../indexes";
2
+ export type IButtonPurpose = 'button' | 'divider' | 'choice';
3
+ export interface IButtonSummary {
4
+ type: IButtonPurpose;
5
+ label: string;
6
+ updates: string[];
7
+ filters: string[];
8
+ fields: string[];
9
+ }
10
+ export interface IButtonsSummary {
11
+ buttons: IButtonSummary[];
12
+ }
13
+ export interface IQuickCommandsDesign extends IQuickCommands {
14
+ summary: IButtonSummary[];
15
+ buttons: IQuickButton[][];
16
+ fields: IQuickField[][];
17
+ }
18
+ /**
19
+ * MEMO TO SELF... THESE TYPES ARE TIED DIRECTLY TO THE keys in the IMinFieldCmds Interface.
20
+ *
21
+ * If you add one here, you need to also update that interface by hand.
22
+ *
23
+ */
24
+ export type IChoiceActionTypes = 'perChoice' | 'promoteChoice' | 'demoteChoice' | 'bracketChoice' | 'rejectLast';
25
+ export type IYesNoActionTypes = 'showOnTrue' | 'showOnFalse' | 'showOnNull' | 'setTrue' | 'setFalse' | 'setToggle';
26
+ export type IUserActionTypes = 'showToUser' | 'hideFromUser' | 'setUser' | 'addUser' | 'removeUser' | 'clearUsers';
27
+ export type IDateActionTypes = 'setToday' | 'set1Week' | 'set1Month' | 'clearDate' | 'depends' | 'showIfPast' | 'showIfFuture';
28
+ export type ITextActionTypes = 'replaceText' | 'promptText' | 'captcha';
29
+ export type INoteActionTypes = 'appendNote' | 'replaceNote';
30
+ export type IAllActionTypes = IChoiceActionTypes | IYesNoActionTypes | IUserActionTypes | IDateActionTypes | ITextActionTypes | INoteActionTypes;
31
+ export type IActionExecType = 'filter' | 'update' | 'special';
32
+ export interface IIconTableRow {
33
+ cmd: IAllActionTypes;
34
+ icon: string;
35
+ head: string;
36
+ title: string;
37
+ type: IActionExecType;
38
+ ignore?: string;
39
+ group?: string;
40
+ oneField?: boolean;
41
+ disabled?: boolean;
42
+ }
43
+ /**
44
+ * Other options for choices in group2
45
+ * filter to only show if current status is one status earlier than button... ie it move's up.
46
+ * So for instance, if the button choices is 2. In Process, only show when status is in 1. Plan
47
+ * This means that you can not go backwards via a button.
48
+ *
49
+ * Alternatively, make button visible if the status is either one above or one below
50
+ *
51
+ * Maybe options are: Promote ( up ), Demote ( down ), Promote/Demote ( up/down )
52
+ */
53
+ export declare const ChoiceFieldActionIcons: IIconTableRow[];
54
+ export declare const ChoiceActions: IAllActionTypes[];
55
+ export declare const YesNoFieldActionIcons: IIconTableRow[];
56
+ export declare const YesNoActions: IAllActionTypes[];
57
+ export declare const UserFieldActionIcons: IIconTableRow[];
58
+ export declare const UserActions: IAllActionTypes[];
59
+ export declare const DateFieldActionIcons: IIconTableRow[];
60
+ export declare const DateActions: IAllActionTypes[];
61
+ export declare const TextFieldActionIcons: IIconTableRow[];
62
+ export declare const TextActions: IAllActionTypes[];
63
+ export declare const NoteFieldActionIcons: IIconTableRow[];
64
+ export declare const NoteActions: IAllActionTypes[];
65
+ export declare const AllFieldActions: IIconTableRow[];
66
+ export declare const AllUpdateActions: IIconTableRow[];
67
+ export declare const AllUpdateActionCmds: IAllActionTypes[];
68
+ export declare const AllActions: IAllActionTypes[];
69
+ //# sourceMappingURL=IAccordion.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IAccordion.d.ts","sourceRoot":"","sources":["../../../../../../src/components/molecules/PropPaneCols/components/command/IAccordion.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAShF,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,CAAE;AAE9D,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,cAAc,CAAC;IACrB,KAAK,EAAE,MAAM,C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,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,eAAe,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAGD;;;;;;;;;GASG;AACF,eAAO,MAAM,sBAAsB,EAAE,aAAa,EAOjD,CAAC;AAEF,eAAO,MAAM,aAAa,mBAAmF,CAAC;AAE9G,eAAO,MAAM,qBAAqB,EAAE,aAAa,EAQhD,CAAC;AAEF,eAAO,MAAM,YAAY,mBAAkF,CAAC;AAG5G,eAAO,MAAM,oBAAoB,EAAE,aAAa,EAO/C,CAAC;AAEF,eAAO,MAAM,WAAW,mBAAiF,CAAC;AAE1G,eAAO,MAAM,oBAAoB,EAAE,aAAa,EAS/C,CAAC;AAEF,eAAO,MAAM,WAAW,mBAAiF,CAAC;AAE1G,eAAO,MAAM,oBAAoB,EAAE,aAAa,EAI/C,CAAC;AAEF,eAAO,MAAM,WAAW,mBAAiF,CAAC;AAE1G,eAAO,MAAM,oBAAoB,EAAE,aAAa,EAG/C,CAAC;AAEF,eAAO,MAAM,WAAW,mBAAiF,CAAC;AAE3G,eAAO,MAAM,eAAe,iBAA+J,CAAC;AAE5L,eAAO,MAAM,gBAAgB,iBAAuE,CAAC;AACrG,eAAO,MAAM,mBAAmB,mBAAuD,CAAC;AAGxF,eAAO,MAAM,UAAU,mBAA4E,CAAC"}
@@ -0,0 +1,73 @@
1
+ // import { IWeb, Web, } from "@pnp/sp/presets/all";
2
+ // import { IMinField, IMinListProps, IsEditable, IFieldPanelFetchState } from "../IPropPaneColsProps";
3
+ // import { IQuickCommands, } from '@mikezimm/fps-library-v2/lib/components/interfaces/QuickCommands/IQuickCommands';
4
+ // // eslint-disable-next-line @typescript-eslint/no-unused-vars
5
+ // import { IGrouping, IViewField } from "@pnp/spfx-controls-react/lib/ListView";
6
+ // // eslint-disable-next-line @typescript-eslint/no-unused-vars
7
+ // import { IFieldInfo, FieldTypes } from "@pnp/sp/presets/all";
8
+ // // eslint-disable-next-line @typescript-eslint/no-unused-vars
9
+ // import { Toggle, } from 'office-ui-fabric-react/lib/Toggle';
10
+ /**
11
+ * Other options for choices in group2
12
+ * filter to only show if current status is one status earlier than button... ie it move's up.
13
+ * So for instance, if the button choices is 2. In Process, only show when status is in 1. Plan
14
+ * This means that you can not go backwards via a button.
15
+ *
16
+ * Alternatively, make button visible if the status is either one above or one below
17
+ *
18
+ * Maybe options are: Promote ( up ), Demote ( down ), Promote/Demote ( up/down )
19
+ */
20
+ export const ChoiceFieldActionIcons = [
21
+ { group: '1', type: 'special', cmd: 'perChoice', icon: 'Stack', head: 'Per', title: 'Create one button to set every choice', oneField: true },
22
+ { group: '2', type: 'filter', cmd: 'promoteChoice', icon: 'Upload', head: 'Promote', title: 'Show button on Previous status - Able to only Promote' },
23
+ { group: '2', type: 'filter', cmd: 'demoteChoice', icon: 'Download', head: 'Demote', title: 'Show button on Higher status - Able to only Demote' },
24
+ { group: '2', type: 'filter', cmd: 'bracketChoice', icon: 'Sort', head: 'Both', title: 'Show button on Previous/Higher status - Able to only Promote/Demote' },
25
+ { group: '3', type: 'filter', cmd: 'rejectLast', icon: 'ReleaseGateError', head: 'Cancel', title: 'Always show last choice - aka Canceled' },
26
+ // { cmd: '', icon: '', head: '', title: '' },
27
+ ];
28
+ export const ChoiceActions = ChoiceFieldActionIcons.map((action) => { return action.cmd; });
29
+ export const YesNoFieldActionIcons = [
30
+ { group: '1', type: 'filter', cmd: 'showOnTrue', icon: 'AcceptMedium', head: 'onYes', title: 'Show if Field = Yes', },
31
+ { group: '1', type: 'filter', cmd: 'showOnFalse', icon: 'Cancel', head: 'onNo', title: 'Show if Field = No', },
32
+ { group: '1', type: 'filter', cmd: 'showOnNull', icon: 'Checkbox', head: 'onEmpty', title: 'Show if Field = Empty', },
33
+ { group: '2', type: 'update', cmd: 'setTrue', icon: 'CheckboxCompositeReversed', head: 'SetYes', title: 'Set Field to Yes', ignore: 'field.ReadOnlyField === true', },
34
+ { group: '2', type: 'update', cmd: 'setFalse', icon: 'BoxMultiplySolid', head: 'SetNo', title: 'Set Field to No', ignore: 'field.ReadOnlyField === true', },
35
+ { group: '2', type: 'update', cmd: 'setToggle', icon: 'ToggleRight', head: 'Toggle', title: 'Toggle value', ignore: 'field.ReadOnlyField === true', disabled: true }, //, disabled: true
36
+ ];
37
+ export const YesNoActions = YesNoFieldActionIcons.map((action) => { return action.cmd; });
38
+ export const UserFieldActionIcons = [
39
+ { group: '1', type: 'filter', cmd: 'showToUser', icon: 'View', head: 'Show', title: 'Show buttons to these users' },
40
+ { group: '1', type: 'filter', cmd: 'hideFromUser', icon: 'Hide3', head: 'Hide', title: 'Hide buttons for these users, Show takes precedance' },
41
+ { group: '2', type: 'update', cmd: 'setUser', icon: 'Contact', head: 'Set', title: 'Set Field as current user', ignore: 'field.ReadOnlyField === true' },
42
+ { group: '2', type: 'update', cmd: 'addUser', icon: 'AddFriend', head: 'Add', title: 'Add User to field if Multi-Select', ignore: 'field.ReadOnlyField === true' },
43
+ { group: '2', type: 'update', cmd: 'removeUser', icon: 'UserRemove', head: 'Remove', title: 'Remove current User from field', ignore: 'field.ReadOnlyField === true' },
44
+ { group: '2', type: 'update', cmd: 'clearUsers', icon: 'Delete', head: 'Clear', title: 'Clear User field', ignore: 'field.ReadOnlyField === true' },
45
+ ];
46
+ export const UserActions = UserFieldActionIcons.map((action) => { return action.cmd; });
47
+ export const DateFieldActionIcons = [
48
+ { group: '1', type: 'update', cmd: 'setToday', icon: 'EventDate', head: 'Today', title: 'Set Field to today', ignore: 'field.ReadOnlyField === true' },
49
+ { group: '1', type: 'update', cmd: 'set1Week', icon: 'CalendarWorkWeek', head: '+1Wk', title: 'Set Field to + 7 days', ignore: 'field.ReadOnlyField === true' },
50
+ { group: '1', type: 'update', cmd: 'set1Month', icon: 'Calendar', head: '+1Mo', title: 'Set Field to + 1 month', ignore: 'field.ReadOnlyField === true' },
51
+ // { group: '1', type: 'update', cmd: 'captcha', icon: 'InputAddress', head: 'Cap', title: 'Prompt to enter field value', ignore: 'field.ReadOnlyField === true' },
52
+ { group: '1', type: 'update', cmd: 'depends', icon: 'BranchFork2', head: 'Depends', title: 'Value depends on JS eval - UPDATE Final Logic', ignore: 'field.ReadOnlyField === true' },
53
+ { group: '1', type: 'update', cmd: 'clearDate', icon: 'Delete', head: 'Clear', title: 'Clear Date field', ignore: 'field.ReadOnlyField === true' },
54
+ { group: '2', type: 'filter', cmd: 'showIfPast', icon: 'Filter', head: '<Now', title: 'Show if Date is in past', ignore: 'field.ReadOnlyField === true', disabled: true },
55
+ { group: '2', type: 'filter', cmd: 'showIfFuture', icon: 'Filter', head: '>Now', title: 'Show if Date is in future', ignore: 'field.ReadOnlyField === true', disabled: true },
56
+ ];
57
+ export const DateActions = DateFieldActionIcons.map((action) => { return action.cmd; });
58
+ export const TextFieldActionIcons = [
59
+ { group: '1', type: 'update', cmd: 'replaceText', icon: 'ActionCenter', head: 'Replace', title: 'Replace Text with your own - must update in props yourself', ignore: 'field.ReadOnlyField === true' },
60
+ { group: '1', type: 'update', cmd: 'promptText', icon: 'Comment', head: 'Prompt', title: 'Prompt to update column', ignore: 'field.ReadOnlyField === true' },
61
+ { group: '1', type: 'update', cmd: 'captcha', icon: 'InputAddress', head: 'Captcha', title: 'Prompt to enter field value - UPDATE Final Logic', ignore: 'field.ReadOnlyField === true' },
62
+ ];
63
+ export const TextActions = TextFieldActionIcons.map((action) => { return action.cmd; });
64
+ export const NoteFieldActionIcons = [
65
+ { group: '1', type: 'update', cmd: 'appendNote', icon: 'CommentAdd', head: 'Append', title: 'Prompt to Append comment to column', ignore: 'field.ReadOnlyField === true' },
66
+ { group: '1', type: 'update', cmd: 'replaceNote', icon: 'Comment', head: 'Replace', title: 'Prompt to Replace column text', ignore: 'field.ReadOnlyField === true' },
67
+ ];
68
+ export const NoteActions = NoteFieldActionIcons.map((action) => { return action.cmd; });
69
+ export const AllFieldActions = [...ChoiceFieldActionIcons, ...YesNoFieldActionIcons, ...UserFieldActionIcons, ...DateFieldActionIcons, ...TextFieldActionIcons, ...NoteFieldActionIcons];
70
+ export const AllUpdateActions = AllFieldActions.filter(field => { return field.type === 'update'; });
71
+ export const AllUpdateActionCmds = AllUpdateActions.map(field => { return field.cmd; });
72
+ export const AllActions = AllFieldActions.map((action) => { return action.cmd; });
73
+ //# sourceMappingURL=IAccordion.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IAccordion.js","sourceRoot":"","sources":["../../../../../../src/components/molecules/PropPaneCols/components/command/IAccordion.ts"],"names":[],"mappings":"AAAA,oDAAoD;AACpD,uGAAuG;AACvG,qHAAqH;AACrH,gEAAgE;AAChE,iFAAiF;AACjF,gEAAgE;AAChE,gEAAgE;AAChE,gEAAgE;AAChE,+DAA+D;AAoE9D;;;;;;;;;GASG;AACF,MAAM,CAAC,MAAM,sBAAsB,GAAoB;IACtD,EAAE,KAAK,EAAE,GAAG,EAAE,IAAI,EAAE,SAAS,EAAE,GAAG,EAAE,WAAW,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,uCAAuC,EAAE,QAAQ,EAAE,IAAI,EAAE;IAC7I,EAAE,KAAK,EAAE,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,uDAAuD,EAAE;IACrJ,EAAE,KAAK,EAAE,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,EAAE,cAAc,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,oDAAoD,EAAE;IAClJ,EAAE,KAAK,EAAE,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE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,CAAA,CAAC,CAAC,CAAC,CAAC;AACrG,MAAM,CAAC,MAAM,mBAAmB,GAAG,gBAAgB,CAAC,GAAG,CAAE,KAAK,CAAC,EAAE,GAAG,OAAO,KAAK,CAAC,GAAG,CAAA,CAAC,CAAC,CAAC,CAAC;AAGxF,MAAM,CAAC,MAAM,UAAU,GAAG,eAAe,CAAC,GAAG,CAAE,CAAE,MAAqB,EAAG,EAAE,GAAG,OAAO,MAAM,CAAC,GAAG,CAAA,CAAC,CAAC,CAAE,CAAC"}
@@ -0,0 +1,9 @@
1
+ import * as React from 'react';
2
+ import { IQuickCommandsDesign } from './IAccordion';
3
+ export interface IPanelItemProps {
4
+ CommandDesign: IQuickCommandsDesign;
5
+ onClosePanel: any;
6
+ }
7
+ declare const SampleDesignHook: React.FC<IPanelItemProps>;
8
+ export default SampleDesignHook;
9
+ //# sourceMappingURL=SampleDesign%20copy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SampleDesign copy.d.ts","sourceRoot":"","sources":["../../../../../../src/components/molecules/PropPaneCols/components/command/SampleDesign copy.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAQ/B,OAAO,EAAkB,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAGpE,MAAM,WAAW,eAAe;IAC9B,aAAa,EAAE,oBAAoB,CAAC;IACpC,YAAY,EAAE,GAAG,CAAC;CACnB;AAMD,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,CA2F/C,CAAA;AAED,eAAe,gBAAgB,CAAC"}
@@ -0,0 +1,61 @@
1
+ import * as React from 'react';
2
+ import { useState } from 'react';
3
+ import { Panel, PanelType } from 'office-ui-fabric-react/lib/Panel';
4
+ import { Icon, } from 'office-ui-fabric-react/lib/Icon';
5
+ const ConstIcon = React.createElement(Icon, { iconName: 'Stack', title: 'Is a choice button', style: {}, "data-fieldtype": 'Choice', className: 'type-filter-icon' });
6
+ // export function getSampleDesign( panelItem: IMinField, onClosePanel: any, searchText: string ) : JSX.Element {
7
+ const SampleDesignHook = (props) => {
8
+ const { CommandDesign } = props;
9
+ //No matter what I do here, I seem to get error 310 whenever trying to do anything with state.
10
+ const [label, setLabel] = useState('');
11
+ const clickSummary = (idx) => {
12
+ console.log('clicked', idx);
13
+ };
14
+ function createButtonRow(button, idx) {
15
+ if (button.type !== 'choice') {
16
+ const text = button.label.split('||');
17
+ // return <div className={ button.type } style={{ position: idx === 0 ? 'relative' : 'absolute' }}>
18
+ return React.createElement("div", { className: button.type, style: null, onClick: () => clickSummary(idx) },
19
+ React.createElement("div", null, text[0]),
20
+ React.createElement("div", null, text.length === 1 ? null : text[1]));
21
+ //ERROR READING TYPE HERE
22
+ }
23
+ else if (idx === 0 || (button.type === 'choice' && CommandDesign.summary[idx - 1].type !== 'choice')) {
24
+ return createChoiceStack(idx); //
25
+ }
26
+ }
27
+ function createChoiceStack(idx) {
28
+ const ChoiceButtonArray = [];
29
+ let i = idx + 0;
30
+ let offset = 0;
31
+ while (i < CommandDesign.summary.length && CommandDesign.summary[i].type === 'choice') {
32
+ ChoiceButtonArray.push(React.createElement("div", { className: 'choice', style: { position: 'absolute', top: `${offset}px`, left: `${offset}px` }, onClick: () => clickSummary(i) },
33
+ React.createElement("div", null, CommandDesign.summary[i].label)));
34
+ i++;
35
+ offset = (i - idx) * 20;
36
+ }
37
+ return React.createElement("div", { className: 'choice-stack', style: { marginBottom: `${offset + 10}px` } }, ChoiceButtonArray);
38
+ }
39
+ // function getClickedButtonFromSummary( idx: number ) : IQuickButton {
40
+ // if ( idx > -1 ) {
41
+ // let equivilantSummary = -1;
42
+ // let ActualButton: IQuickButton = null;
43
+ // CommandDesign.buttons.map( ( buttonRow: IQuickButton[] ) => {
44
+ // buttonRow.map( ( button: IQuickButton ) => {
45
+ // equivilantSummary ++;
46
+ // if ( idx === equivilantSummary ) ActualButton = button ;
47
+ // });
48
+ // } );
49
+ // return ActualButton;
50
+ // } else return null;
51
+ // }
52
+ // const clickedSummary = 999;
53
+ // const ActionCommand: IQuickButton = getClickedButtonFromSummary( clickedSummary );
54
+ const AttachPanel = React.createElement(Panel, { isOpen: CommandDesign.buttons.length > 0 ? true : false, type: PanelType.medium,
55
+ // onDismiss={ onClosePanel }
56
+ onDismiss: () => props.onClosePanel(), headerText: `Sample Button Sett`, closeButtonAriaLabel: "Close", isLightDismiss: true },
57
+ React.createElement("div", { className: 'sample-panel' }, CommandDesign.summary.map((summary, idx) => createButtonRow(summary, idx))));
58
+ return (AttachPanel);
59
+ };
60
+ export default SampleDesignHook;
61
+ //# sourceMappingURL=SampleDesign%20copy.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SampleDesign copy.js","sourceRoot":"","sources":["../../../../../../src/components/molecules/PropPaneCols/components/command/SampleDesign copy.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,QAAQ,EAAa,MAAM,OAAO,CAAC;AAE5C,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,IAAI,GAAG,MAAM,iCAAiC,CAAC;AAYxD,MAAM,SAAS,GAAG,oBAAC,IAAI,IAAC,QAAQ,EAAG,OAAO,EAAG,KAAK,EAAG,oBAAoB,EAAG,KAAK,EAAE,EAAI,oBACnE,QAAQ,EAAC,SAAS,EAAG,kBAAkB,GAAK,CAAA;AAEhE,iHAAiH;AACjH,MAAM,gBAAgB,GAA8B,CAAE,KAAK,EAAG,EAAE;IAE9D,MAAM,EAAE,aAAa,EAAE,GAAG,KAAK,CAAC;IAEhC,8FAA8F;IAC9F,MAAM,CAAE,KAAK,EAAE,QAAQ,CAAE,GAAG,QAAQ,CAAS,EAAE,CAAC,CAAC;IAEjD,MAAM,YAAY,GAAG,CAAE,GAAW,EAAU,EAAE;QAC5C,OAAO,CAAC,GAAG,CAAE,SAAS,EAAE,GAAG,CAAE,CAAA;IAC/B,CA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React from 'react';
2
+ import { IQuickCommandsDesign } from './IAccordion';
3
+ export interface IPanelItemProps {
4
+ CommandDesign: IQuickCommandsDesign;
5
+ onClosePanel: any;
6
+ showPanel: boolean;
7
+ }
8
+ declare const SampleDesignHook: React.FC<IPanelItemProps>;
9
+ export default SampleDesignHook;
10
+ //# sourceMappingURL=SampleDesign.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SampleDesign.d.ts","sourceRoot":"","sources":["../../../../../../src/components/molecules/PropPaneCols/components/command/SampleDesign.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAM/B,OAAO,EAAkB,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAIpE,MAAM,WAAW,eAAe;IAC9B,aAAa,EAAE,oBAAoB,CAAC;IACpC,YAAY,EAAE,GAAG,CAAC;IAClB,SAAS,EAAE,OAAO,CAAC;CACpB;AAMD,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,CAsF/C,CAAA;AAED,eAAe,gBAAgB,CAAC"}
@@ -0,0 +1,66 @@
1
+ import * as React from 'react';
2
+ import { useState } from 'react';
3
+ import { Panel, PanelType } from 'office-ui-fabric-react/lib/Panel';
4
+ import { panelActionToggles } from '../common';
5
+ // const ConstIcon = <Icon iconName={ 'Stack' } title={ 'Is a choice button' } style={{ }}
6
+ // data-fieldtype= 'Choice' className={ 'type-filter-icon' } />
7
+ // export function getSampleDesign( panelItem: IMinField, onClosePanel: any, searchText: string ) : JSX.Element {
8
+ const SampleDesignHook = (props) => {
9
+ const { CommandDesign, showPanel } = props;
10
+ // Setting state in any way causes react error 310.
11
+ // https://github.com/mikezimm/Pnpjs-v2-Upgrade-sample/issues/36
12
+ const [type, setSide] = useState(PanelType.custom);
13
+ const [blocking, setBlock] = useState(true);
14
+ // For https://github.com/mikezimm/Pnpjs-v2-Upgrade-sample/issues/36
15
+ const clickSummary = (idx) => {
16
+ console.log('clicked', idx);
17
+ if (idx > -1) {
18
+ let equivilantSummary = -1;
19
+ let ActualButton = null;
20
+ CommandDesign.buttons.map((buttonRow) => {
21
+ buttonRow.map((button) => {
22
+ equivilantSummary++;
23
+ if (idx === equivilantSummary)
24
+ ActualButton = button;
25
+ });
26
+ });
27
+ console.log('ActualButton', ActualButton);
28
+ alert(`Clicked ${ActualButton.label.replace(`{str1}`, ActualButton.str1)}, Check console for details.`);
29
+ }
30
+ };
31
+ function createButtonRow(button, idx) {
32
+ if (button.type !== 'choice') {
33
+ const text = button.label.split('||');
34
+ // return <div className={ button.type } style={{ position: idx === 0 ? 'relative' : 'absolute' }}>
35
+ return React.createElement("div", { className: button.type, style: null, onClick: () => clickSummary(idx) },
36
+ React.createElement("div", null, text[0]),
37
+ React.createElement("div", null, text.length === 1 ? null : text[1]));
38
+ //ERROR READING TYPE HERE
39
+ }
40
+ else if (idx === 0 || (button.type === 'choice' && CommandDesign.summary[idx - 1].type !== 'choice')) {
41
+ return createChoiceStack(idx); //
42
+ }
43
+ }
44
+ function createChoiceStack(idx) {
45
+ const ChoiceButtonArray = [];
46
+ let i = idx + 0;
47
+ let offset = 0;
48
+ while (i < CommandDesign.summary.length && CommandDesign.summary[i].type === 'choice') {
49
+ const whileIndex = i + 0; // Had to create this or the clickSummary( ) would always just show the last index.
50
+ ChoiceButtonArray.push(React.createElement("div", { className: 'choice', style: { position: 'absolute', top: `${offset}px`, left: `${offset}px` }, onClick: () => clickSummary(whileIndex) },
51
+ React.createElement("div", null, CommandDesign.summary[i].label)));
52
+ i++;
53
+ offset = (i - idx) * 20;
54
+ }
55
+ return React.createElement("div", { className: 'choice-stack', style: { marginBottom: `${offset + 10}px` } }, ChoiceButtonArray);
56
+ }
57
+ // const IconStyles: React.CSSProperties = { cursor: 'pointer', fontSize: 'x-large', marginLeft: '20px' };
58
+ const AttachPanel = showPanel !== true ? null : React.createElement(Panel, { isOpen: CommandDesign.buttons.length > 0 ? true : false, type: type, isBlocking: blocking,
59
+ // onDismiss={ onClosePanel }
60
+ onDismiss: () => props.onClosePanel(false), headerText: `Sample Button Set`, closeButtonAriaLabel: "Close", isLightDismiss: true, customWidth: '700px' },
61
+ panelActionToggles(type, blocking, setSide, null),
62
+ React.createElement("div", { className: 'sample-panel' }, CommandDesign.summary.map((summary, idx) => createButtonRow(summary, idx))));
63
+ return (AttachPanel);
64
+ };
65
+ export default SampleDesignHook;
66
+ //# sourceMappingURL=SampleDesign.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SampleDesign.js","sourceRoot":"","sources":["../../../../../../src/components/molecules/PropPaneCols/components/command/SampleDesign.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,QAAQ,EAAa,MAAM,OAAO,CAAC;AAE5C,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAKpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAQ/C,2FAA2F;AAC3F,mEAAmE;AAEnE,iHAAiH;AACjH,MAAM,gBAAgB,GAA8B,CAAE,KAAK,EAAG,EAAE;IAE9D,MAAM,EAAE,aAAa,EAAE,SAAS,EAAE,GAAG,KAAK,CAAC;IAE3C,mDAAmD;IACnD,gEAAgE;IAEhE,MAAM,CAAE,IAAI,EAAE,OAAO,CAAE,GAAG,QAAQ,CAAa,SAAS,CAAC,MAAM,CAAE,CAAC;IAClE,MAAM,CAAE,QAAQ,EAAE,QAAQ,CAAE,GAAG,QAAQ,CAAW,IAAI,CAAE,CAAC;IAEzD,oEAAoE;IACpE,MAAM,YAAY,GAAG,CAAE,GAAW,EAAU,EAAE;QAC5C,OAAO,CAAC,GAAG,CAAE,SAAS,EAAE,GAAG,CAAE,CAAC;QAE9B,IAAK,GAAG,GAAG,CAAC,CAAC,EAAG;YACd,IAAI,iBAAiB,GAAG,CAAC,CAAC,CAAC;YAC3B,IAAI,YAAY,GAAiB,IAAI,CAAC;YACtC,aAAa,CAAC,O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YAAY,CAAE,KAAK,CAAE,EAC7C,UAAU,EAAG,mBAAmB,EAChC,oBAAoB,EAAC,OAAO,EAC5B,cAAc,EAAG,IAAI,EACrB,WAAW,EAAG,OAAO;QAErB,kBAAkB,CAAG,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,IAAI,CAAE;QACtD,6BAAK,SAAS,EAAC,cAAc,IACzB,aAAa,CAAC,OAAO,CAAC,GAAG,CAAE,CAAE,OAAuB,EAAE,GAAW,EAAG,EAAE,CAAC,eAAe,CAAG,OAAO,EAAE,GAAG,CAAE,CAAE,CACvG,CAEF,CAAC;IAEX,OAAO,CAAE,WAAW,CAAE,CAAC;AAEzB,CAAC,CAAA;AAED,eAAe,gBAAgB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { IMinField } from "../IPropPaneColsProps";
2
+ import { IQuickCommandsDesign } from './IAccordion';
3
+ export declare function buildQuickCommands(selected: IMinField[], title: string, description: string): IQuickCommandsDesign;
4
+ /**
5
+ * This will take the eval string and add a new eval to it including having the operator and adding surround braces when required.
6
+ * @param showWhenEvalTrue
7
+ * @param operator
8
+ * @param miniEval
9
+ * @param surround
10
+ * @returns
11
+ */
12
+ export declare function bumpEval(showWhenEvalTrue: string, operator: '||' | '&&', miniEval: string, surround: boolean): string;
13
+ //# sourceMappingURL=createLogic.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createLogic.d.ts","sourceRoot":"","sources":["../../../../../../src/components/molecules/PropPaneCols/components/command/createLogic.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,SAAS,EAAiB,MAAM,uBAAuB,CAAC;AAMjE,OAAO,EAAiB,oBAAoB,EAAmB,MAAM,cAAc,CAAA;AAgEnF,wBAAgB,kBAAkB,CAAG,QAAQ,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAI,oBAAoB,CAsTrH;AAED;;;;;;;GAOG;AACH,wBAAgB,QAAQ,CAAE,gBAAgB,EAAE,MAAM,EAAG,QAAQ,EAAE,IAAI,GAAG,IAAI,EAAG,QAAQ,EAAE,MAAM,EAAG,QAAQ,EAAE,OAAO,GAAI,MAAM,CAe1H"}