@mikezimm/fps-library-v2 1.0.148 → 1.0.150

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 (92) hide show
  1. package/CHANGELOG.md +52 -27
  2. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardProps.d.ts +12 -0
  3. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardProps.d.ts.map +1 -0
  4. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardProps.js +2 -0
  5. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardProps.js.map +1 -0
  6. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardState.d.ts +5 -0
  7. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardState.d.ts.map +1 -0
  8. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardState.js +2 -0
  9. package/lib/components/atoms/PersonaCard/Interfaces/IPersonaCardState.js.map +1 -0
  10. package/lib/components/atoms/PersonaCard/Interfaces/IUserProperties.d.ts +13 -0
  11. package/lib/components/atoms/PersonaCard/Interfaces/IUserProperties.d.ts.map +1 -0
  12. package/lib/components/atoms/PersonaCard/Interfaces/IUserProperties.js +2 -0
  13. package/lib/components/atoms/PersonaCard/Interfaces/IUserProperties.js.map +1 -0
  14. package/lib/components/atoms/PersonaCard/Interfaces/StandardPersonIconNames.d.ts +5 -0
  15. package/lib/components/atoms/PersonaCard/Interfaces/StandardPersonIconNames.d.ts.map +1 -0
  16. package/lib/components/atoms/PersonaCard/Interfaces/StandardPersonIconNames.js +5 -0
  17. package/lib/components/atoms/PersonaCard/Interfaces/StandardPersonIconNames.js.map +1 -0
  18. package/lib/components/atoms/PersonaCard/PersonaCard.d.ts +57 -0
  19. package/lib/components/atoms/PersonaCard/PersonaCard.d.ts.map +1 -0
  20. package/lib/components/atoms/PersonaCard/PersonaCard.js +233 -0
  21. package/lib/components/atoms/PersonaCard/PersonaCard.js.map +1 -0
  22. package/lib/components/atoms/PersonaCard/PersonaIcons.d.ts +4 -0
  23. package/lib/components/atoms/PersonaCard/PersonaIcons.d.ts.map +1 -0
  24. package/lib/components/atoms/PersonaCard/PersonaIcons.js +16 -0
  25. package/lib/components/atoms/PersonaCard/PersonaIcons.js.map +1 -0
  26. package/lib/components/atoms/PersonaCard/PersonaRow.d.ts +54 -0
  27. package/lib/components/atoms/PersonaCard/PersonaRow.d.ts.map +1 -0
  28. package/lib/components/atoms/PersonaCard/PersonaRow.js +116 -0
  29. package/lib/components/atoms/PersonaCard/PersonaRow.js.map +1 -0
  30. package/lib/components/atoms/Suggestions/ISuggestion.d.ts +14 -0
  31. package/lib/components/atoms/Suggestions/ISuggestion.d.ts.map +1 -0
  32. package/lib/components/atoms/Suggestions/ISuggestion.js +5 -0
  33. package/lib/components/atoms/Suggestions/ISuggestion.js.map +1 -0
  34. package/lib/components/atoms/Suggestions/SuggestionsSample-Labels.d.ts +17 -0
  35. package/lib/components/atoms/Suggestions/SuggestionsSample-Labels.d.ts.map +1 -0
  36. package/lib/components/atoms/Suggestions/SuggestionsSample-Labels.js +89 -0
  37. package/lib/components/atoms/Suggestions/SuggestionsSample-Labels.js.map +1 -0
  38. package/lib/components/atoms/Suggestions/convertSugsLC.d.ts +10 -0
  39. package/lib/components/atoms/Suggestions/convertSugsLC.d.ts.map +1 -0
  40. package/lib/components/atoms/Suggestions/convertSugsLC.js +18 -0
  41. package/lib/components/atoms/Suggestions/convertSugsLC.js.map +1 -0
  42. package/lib/components/atoms/Suggestions/getSuggestionsByKeys.d.ts +7 -0
  43. package/lib/components/atoms/Suggestions/getSuggestionsByKeys.d.ts.map +1 -0
  44. package/lib/components/atoms/Suggestions/getSuggestionsByKeys.js +54 -0
  45. package/lib/components/atoms/Suggestions/getSuggestionsByKeys.js.map +1 -0
  46. package/lib/components/atoms/WordSummary/IWordSummary.d.ts +19 -0
  47. package/lib/components/atoms/WordSummary/IWordSummary.d.ts.map +1 -0
  48. package/lib/components/atoms/WordSummary/IWordSummary.js +2 -0
  49. package/lib/components/atoms/WordSummary/IWordSummary.js.map +1 -0
  50. package/lib/components/atoms/WordSummary/buildWordSummary.d.ts +5 -0
  51. package/lib/components/atoms/WordSummary/buildWordSummary.d.ts.map +1 -0
  52. package/lib/components/atoms/WordSummary/buildWordSummary.js +67 -0
  53. package/lib/components/atoms/WordSummary/buildWordSummary.js.map +1 -0
  54. package/lib/components/molecules/ModernPages/Interfaces/IModernPage.d.ts +25 -0
  55. package/lib/components/molecules/ModernPages/Interfaces/IModernPage.d.ts.map +1 -0
  56. package/lib/components/molecules/ModernPages/Interfaces/IModernPage.js +13 -0
  57. package/lib/components/molecules/ModernPages/Interfaces/IModernPage.js.map +1 -0
  58. package/lib/components/molecules/SearchPage/Interfaces/ISourceSearch.d.ts +1 -0
  59. package/lib/components/molecules/SearchPage/Interfaces/ISourceSearch.d.ts.map +1 -1
  60. package/lib/components/molecules/SearchPage/component/SearchBoxRow.d.ts +18 -0
  61. package/lib/components/molecules/SearchPage/component/SearchBoxRow.d.ts.map +1 -0
  62. package/lib/components/molecules/SearchPage/component/SearchBoxRow.js +25 -0
  63. package/lib/components/molecules/SearchPage/component/SearchBoxRow.js.map +1 -0
  64. package/lib/components/molecules/SearchPage/functions/getFilteredV1.d.ts +20 -0
  65. package/lib/components/molecules/SearchPage/functions/getFilteredV1.d.ts.map +1 -0
  66. package/lib/components/molecules/SearchPage/functions/getFilteredV1.js +127 -0
  67. package/lib/components/molecules/SearchPage/functions/getFilteredV1.js.map +1 -0
  68. package/lib/components/molecules/SourceList/ItemPane/IItemPaneProps.d.ts +30 -0
  69. package/lib/components/molecules/SourceList/ItemPane/IItemPaneProps.d.ts.map +1 -0
  70. package/lib/components/molecules/SourceList/ItemPane/IItemPaneProps.js +2 -0
  71. package/lib/components/molecules/SourceList/ItemPane/IItemPaneProps.js.map +1 -0
  72. package/lib/components/molecules/SourceList/ItemPane/component.d.ts +36 -0
  73. package/lib/components/molecules/SourceList/ItemPane/component.d.ts.map +1 -0
  74. package/lib/components/molecules/SourceList/ItemPane/component.js +263 -0
  75. package/lib/components/molecules/SourceList/ItemPane/component.js.map +1 -0
  76. package/lib/logic/Regex/constants.d.ts +12 -0
  77. package/lib/logic/Regex/constants.d.ts.map +1 -1
  78. package/lib/logic/Regex/constants.js +13 -0
  79. package/lib/logic/Regex/constants.js.map +1 -1
  80. package/lib/logic/Strings/getStringArrayBasic.d.ts +26 -0
  81. package/lib/logic/Strings/getStringArrayBasic.d.ts.map +1 -0
  82. package/lib/logic/Strings/getStringArrayBasic.js +42 -0
  83. package/lib/logic/Strings/getStringArrayBasic.js.map +1 -0
  84. package/lib/logic/Strings/getWordsFromString.d.ts +15 -0
  85. package/lib/logic/Strings/getWordsFromString.d.ts.map +1 -1
  86. package/lib/logic/Strings/getWordsFromString.js +29 -7
  87. package/lib/logic/Strings/getWordsFromString.js.map +1 -1
  88. package/lib/logic/Time/getFPSPrefNavLang.js +1 -1
  89. package/lib/logic/Time/getFPSPrefNavLang.js.map +1 -1
  90. package/lib/pnpjs/SourceItems/Interface.d.ts +3 -0
  91. package/lib/pnpjs/SourceItems/Interface.d.ts.map +1 -1
  92. package/package.json +2 -2
@@ -0,0 +1,18 @@
1
+ import * as React from 'react';
2
+ export type ISourceSearchLayout = 'flex' | 'block';
3
+ export interface ISourceSearchHookProps {
4
+ searchText: string;
5
+ searchTime: number;
6
+ layout?: ISourceSearchLayout;
7
+ _onSearchChange(event?: React.ChangeEvent<HTMLInputElement>, NewSearch?: string): void;
8
+ _updateFirstLastVisible(firstVisible: number, lastVisible: number): void;
9
+ preArrowsEle?: JSX.Element;
10
+ postArrowsEle?: JSX.Element;
11
+ resetArrows: any;
12
+ itemsPerPage: number;
13
+ debugMode: boolean;
14
+ itemCount: number;
15
+ }
16
+ declare const SourceSearchHook: React.FC<ISourceSearchHookProps>;
17
+ export default SourceSearchHook;
18
+ //# sourceMappingURL=SearchBoxRow.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SearchBoxRow.d.ts","sourceRoot":"","sources":["../../../../../src/components/molecules/SearchPage/component/SearchBoxRow.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AA6B/B,MAAM,MAAM,mBAAmB,GAAG,MAAM,GAAG,OAAO,CAAC;AAEnD,MAAM,WAAW,sBAAsB;IACrC,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,mBAAmB,CAAC;IAE7B,eAAe,CAAE,KAAK,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,gBAAgB,CAAC,EAAE,SAAS,CAAC,EAAE,MAAM,GAAK,IAAI,CAAC;IAC1F,uBAAuB,CAAE,YAAY,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAK,IAAI,CAAC;IAE5E,YAAY,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC;IAC3B,aAAa,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC;IAE5B,WAAW,EAAE,GAAG,CAAC;IAEjB,YAAY,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,OAAO,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;CAEnB;AAED,QAAA,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CA4CtD,CAAA;AAED,eAAe,gBAAgB,CAAC"}
@@ -0,0 +1,25 @@
1
+ import * as React from 'react';
2
+ // import styles from './SourceSearch.module.scss';
3
+ import { SearchBox } from 'office-ui-fabric-react/lib/SearchBox';
4
+ import PageArrows from '../../Arrows/PageArrows';
5
+ require('@mikezimm/fps-styles/dist/searchBoxRow.css');
6
+ const SourceSearchHook = (props) => {
7
+ const { searchText, searchTime, _onSearchChange, _updateFirstLastVisible, debugMode, resetArrows, itemsPerPage, itemCount, } = props;
8
+ // I don't think checking counts will work here as
9
+ // NOTE this itemCount <= itemsPerPage should be verified with -1, -= +1 actual items.
10
+ // const pageArrows = itemCount <= itemsPerPage ? undefined : <PageArrows
11
+ const pageArrows = React.createElement(PageArrows, { itemCount: itemCount, itemsPerPage: itemsPerPage, setParentStateFirstLast: _updateFirstLastVisible.bind(this), debugMode: debugMode, fontSize: 20, resetArrows: resetArrows, pageArrowStyles: props.layout === 'block' ? { paddingLeft: '0px' } : {} });
12
+ const containerClass = props.layout === 'block' ? 'searchContainerBlock' : 'searchContainerFlex';
13
+ /*https://developer.microsoft.com/en-us/fabric#/controls/web/searchbox*/
14
+ const searchBox = React.createElement("div", { className: [containerClass].join(' ') },
15
+ React.createElement(SearchBox, { className: 'searchBox', styles: { root: { maxWidth: 250 } }, placeholder: "Search", value: searchText, onSearch: _onSearchChange, onFocus: () => console.log('onFocus called'), onBlur: () => console.log('onBlur called'), onChange: _onSearchChange, onClear: _onSearchChange }),
16
+ React.createElement("div", { className: 'searchStatus' },
17
+ 'Searching ' + itemCount + ' items',
18
+ searchTime === null ? '' : ' ~ Time ' + searchTime + ' ms'),
19
+ props.preArrowsEle ? props.preArrowsEle : undefined,
20
+ pageArrows,
21
+ props.postArrowsEle ? props.postArrowsEle : undefined);
22
+ return (searchBox);
23
+ };
24
+ export default SourceSearchHook;
25
+ //# sourceMappingURL=SearchBoxRow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SearchBoxRow.js","sourceRoot":"","sources":["../../../../../src/components/molecules/SearchPage/component/SearchBoxRow.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,mDAAmD;AAEnD,OAAO,EAAE,SAAS,EAAE,MAAM,sCAAsC,CAAC;AAEjE,OAAO,UAAU,MAAM,yBAAyB,CAAC;AAEjD,OAAO,CAAG,4CAA4C,CAAC,CAAC;AA2CxD,MAAM,gBAAgB,GAAqC,CAAE,KAAK,EAAG,EAAE;IAErE,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,eAAe,EAAE,uBAAuB,EAAE,SAAS,EAAE,WAAW,EAAE,YAAY,EAAE,SAAS,GAAG,GAA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AC,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC,SAAS;QACnD,UAAU;QACV,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,SAAS,CACnD,CAAC;IAET,OAAO,CAAE,SAAS,CAAE,CAAC;AAEvB,CAAC,CAAA;AAED,eAAe,gBAAgB,CAAC"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * 2023-03-28: Originally copied from Compliance web part but is identical to
3
+ * src\webparts\alvFinMan\components\Search\functions.ts
4
+ */
5
+ import { IAnySourceItem } from "../../SourceList/IAnyContent";
6
+ import { ISearchTypes } from "../Interfaces/ISearchTypes";
7
+ /**
8
+ *
9
+ * @param startingItems
10
+ * @param text - this is the search text
11
+ * @param top - these are the selected top buttons if multi-selected
12
+ * @param left - these are the selected left buttons if multi-selected
13
+ * @param type - these are the selected type buttons if multi-selected
14
+ * @param searchStrings - these are the selected buttons if multi-selected... I think :)
15
+ * @param UseSearchTypes
16
+ * @returns
17
+ */
18
+ export declare function getFilteredItems(startingItems: IAnySourceItem[], text: string, top: string[], left: string[], type: string[], searchStrings: string[], UseSearchTypes?: ISearchTypes): IAnySourceItem[];
19
+ export declare function doesPassButtonSearch(item: IAnySourceItem, searchStrings: string[]): boolean;
20
+ //# sourceMappingURL=getFilteredV1.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getFilteredV1.d.ts","sourceRoot":"","sources":["../../../../../src/components/molecules/SearchPage/functions/getFilteredV1.ts"],"names":[],"mappings":"AACA;;;GAGG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAG1D;;;;;;;;;;GAUG;AACH,wBAAgB,gBAAgB,CAAE,aAAa,EAAE,cAAc,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,aAAa,EAAE,MAAM,EAAE,EAAE,cAAc,GAAE,YAA0B,GAAI,cAAc,EAAE,CAmDtN;AAGD,wBAAgB,oBAAoB,CAAE,IAAI,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,EAAE,GAAK,OAAO,CAwD9F"}
@@ -0,0 +1,127 @@
1
+ /**
2
+ * 2023-03-28: Originally copied from Compliance web part but is identical to
3
+ * src\webparts\alvFinMan\components\Search\functions.ts
4
+ */
5
+ import { SearchTypes } from "../Interfaces/StandardTypes";
6
+ /**
7
+ *
8
+ * @param startingItems
9
+ * @param text - this is the search text
10
+ * @param top - these are the selected top buttons if multi-selected
11
+ * @param left - these are the selected left buttons if multi-selected
12
+ * @param type - these are the selected type buttons if multi-selected
13
+ * @param searchStrings - these are the selected buttons if multi-selected... I think :)
14
+ * @param UseSearchTypes
15
+ * @returns
16
+ */
17
+ export function getFilteredItems(startingItems, text, top, left, type, searchStrings, UseSearchTypes = SearchTypes) {
18
+ const filteredItems = [];
19
+ startingItems.map(item => {
20
+ let passMe = true;
21
+ if (left.length > 0) {
22
+ let passThis = false;
23
+ item.leftSearch.map(test => {
24
+ if (left.indexOf(test) > -1) {
25
+ passThis = true;
26
+ }
27
+ });
28
+ if (passThis === false) {
29
+ passMe = false;
30
+ }
31
+ }
32
+ if (top.length > 0 && passMe === true) {
33
+ let passThis = false;
34
+ item.topSearch.map(test => {
35
+ if (top.indexOf(test) > -1) {
36
+ passThis = true;
37
+ }
38
+ });
39
+ if (passThis === false) {
40
+ passMe = false;
41
+ }
42
+ }
43
+ if (type.length > 0 && passMe === true) {
44
+ // Close https://github.com/mikezimm/ALVFinMan/issues/122
45
+ const typeObj = UseSearchTypes.objs[item.typeIdx];
46
+ if (type.indexOf(typeObj.key) < 0) {
47
+ passMe = false;
48
+ }
49
+ }
50
+ //Separate logic from SearchPage.tsx search... this looks at the searchTextLC for simpler execution
51
+ if (passMe === true) {
52
+ // NOTE: ALVFinMan had commented out code here... This was just moved into function: doesPassButtonSearch
53
+ const passThis = doesPassButtonSearch(item, searchStrings);
54
+ if (passThis === false) {
55
+ passMe = false;
56
+ }
57
+ }
58
+ if (passMe === true && text && text.length > 0) {
59
+ if (item.searchTextLC.indexOf(text.toLowerCase()) < 0) {
60
+ passMe = false;
61
+ }
62
+ }
63
+ if (passMe === true) {
64
+ filteredItems.push(item);
65
+ }
66
+ });
67
+ console.log(' filteredItems: ', filteredItems);
68
+ return filteredItems;
69
+ }
70
+ export function doesPassButtonSearch(item, searchStrings) {
71
+ if (!searchStrings || searchStrings.length === 0) {
72
+ return true;
73
+ }
74
+ let passThis = false;
75
+ let countNotNull = 0;
76
+ // 2023-02-23: Added from ALVFM for when CTRL-Unselecting all items... the array searchStrings can be like this causing error: [ null ]
77
+ searchStrings.map(searchObjectFull => {
78
+ if (searchObjectFull) {
79
+ countNotNull++;
80
+ const searchSplits = searchObjectFull.split('==');
81
+ const searchTest = searchSplits[0];
82
+ const searchTestLC = searchTest.toLowerCase();
83
+ if (searchSplits.length === 1) { //First test if it is simple search
84
+ if (item.searchTextLC.indexOf(searchTestLC) > -1) {
85
+ passThis = true;
86
+ }
87
+ }
88
+ else { //If not simple, proceed to more complex search
89
+ if (searchSplits[1].toLowerCase() === 'proper' || searchSplits[1].toLowerCase() === 'exact') {
90
+ if (item.searchText.indexOf(searchTest) > -1) {
91
+ passThis = true;
92
+ }
93
+ }
94
+ else if (searchSplits[1].indexOf('/') === 0) {
95
+ const regexParams = searchSplits[1].split('/');
96
+ if (regexParams.length < 3) {
97
+ console.log('INVALID SEARCH REGEX: ', searchObjectFull);
98
+ }
99
+ else {
100
+ // const regexParams = searchSplits[1].substring(nextSlash + 1);
101
+ const regex = new RegExp(regexParams[1], regexParams[2]); // eslint-disable-line @rushstack/security/no-unsafe-regexp
102
+ const matches = item.searchText.match(regex);
103
+ if ((matches === null || matches === void 0 ? void 0 : matches.length) > 0) {
104
+ passThis = true;
105
+ }
106
+ }
107
+ }
108
+ else if (searchSplits[1].indexOf('item.') === 0) {
109
+ //This will Target the property of the item, not case sensitive
110
+ const itemColumn = searchSplits[1].substring(5);
111
+ const columnValue = item[itemColumn] ? item[itemColumn] : '';
112
+ if (columnValue && typeof columnValue === 'string' && columnValue.toLowerCase().indexOf(searchTestLC) > -1) {
113
+ passThis = true;
114
+ }
115
+ }
116
+ else {
117
+ //default to string search if no paramter was provided
118
+ if (item.searchTextLC.indexOf(searchTestLC) > -1) {
119
+ passThis = true;
120
+ }
121
+ }
122
+ } // End if basic Search or Complex Search
123
+ }
124
+ }); // End map Search Strings
125
+ return countNotNull > 0 ? passThis : true;
126
+ }
127
+ //# sourceMappingURL=getFilteredV1.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getFilteredV1.js","sourceRoot":"","sources":["../../../../../src/components/molecules/SearchPage/functions/getFilteredV1.ts"],"names":[],"mappings":"AACA;;;GAGG;AAIH,OAAO,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAE1D;;;;;;;;;;GAUG;AACH,MAAM,UAAU,gBAAgB,CAAE,aAA+B,EAAE,IAAY,EAAE,GAAa,EAAE,IAAc,EAAE,IAAc,EAAE,aAAuB,EAAE,iBAA+B,WAAW;IAEjM,MAAM,aAAa,GAAsB,EAAE,CAAC;IAE5C,aAAa,CAAC,GAAG,CAAE,IAAI,CAAC,EAAE;QAExB,IAAI,MAAM,GAAG,IAAI,CAAC;QAElB,IAAK,IAAI,CAAC,MAAM,GAAG,CAAC,EAAG;YACrB,IAAI,QAAQ,GAAY,KAAK,CAAC;YAC9B,IAAI,CAAC,UAAU,CAAC,GAAG,CAAE,IAAI,CAAC,EAAE;gBAC1B,IAAK,IAAI,CAAC,OAAO,CAAE,IAAI,CAAE,GAAG,CAAC,CAAC,EAAG;oBAAE,QAAQ,GAAG,IAAI,CAAE;iBAAE;YACxD,CAAC,CAAC,CAAC;YACH,IAAK,QAAQ,KAAK,KAAK,EAAG;gBAAE,MAAM,GAAG,KAAK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AAC,CAAC,CAAC,CAAC,yBAAyB;IAE7B,OAAO,YAAY,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAE;AAE7C,CAAC"}
@@ -0,0 +1,30 @@
1
+ /// <reference types="react" />
2
+ import { ISourceInfo, ISourceProps } from "../../../../pnpjs/SourceItems/Interface";
3
+ import { ICanvasContentOptions } from "../../ModernPages/Interfaces/IModernPage";
4
+ import { ISourceSearch } from "../../SearchPage/Interfaces/ISourceSearch";
5
+ import { IAnySourceItem } from "../IAnyContent";
6
+ export interface IItemPaneWPProps {
7
+ imageStyle: string;
8
+ topButtons: string[];
9
+ canvasOptions: ICanvasContentOptions;
10
+ debugMode?: boolean;
11
+ showJSONDetail?: boolean;
12
+ showItemLink?: boolean;
13
+ showListLink?: boolean;
14
+ showDateStamps?: boolean;
15
+ }
16
+ export interface IItemPaneProps extends IItemPaneWPProps {
17
+ item: IAnySourceItem;
18
+ showCanvasContent1: boolean;
19
+ search: ISourceSearch;
20
+ source: ISourceInfo;
21
+ primarySource: ISourceProps;
22
+ refreshId: string;
23
+ customElement1?: JSX.Element;
24
+ customElement2?: JSX.Element;
25
+ }
26
+ export interface IItemPaneState {
27
+ showPanelJSON: boolean;
28
+ showThisItem: IAnySourceItem;
29
+ }
30
+ //# sourceMappingURL=IItemPaneProps.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IItemPaneProps.d.ts","sourceRoot":"","sources":["../../../../../src/components/molecules/SourceList/ItemPane/IItemPaneProps.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AACpF,OAAO,EAAE,qBAAqB,EAAE,MAAM,0CAA0C,CAAC;AACjF,OAAO,EAAE,aAAa,EAAE,MAAM,2CAA2C,CAAC;AAC1E,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,MAAM,WAAW,gBAAgB;IAE/B,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,EAAE,CAAC;IAErB,aAAa,EAAE,qBAAqB,CAAC;IAErC,SAAS,CAAC,EAAE,OAAO,CAAC;IAGpB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,cAAc,CAAC,EAAE,OAAO,CAAC;CAE1B;AAGD,MAAM,WAAW,cAAe,SAAQ,gBAAgB;IAEtD,IAAI,EAAE,cAAc,CAAC;IAErB,kBAAkB,EAAE,OAAO,CAAC;IAE5B,MAAM,EAAE,aAAa,CAAE;IAEvB,MAAM,EAAE,WAAW,CAAC;IACpB,aAAa,EAAE,YAAY,CAAC;IAE5B,SAAS,EAAE,MAAM,CAAC;IAElB,cAAc,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC;IAC7B,cAAc,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC;CAE9B;AAED,MAAM,WAAW,cAAc;IAE7B,aAAa,EAAE,OAAO,CAAC;IACvB,YAAY,EAAE,cAAc,CAAC;CAE9B"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=IItemPaneProps.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IItemPaneProps.js","sourceRoot":"","sources":["../../../../../src/components/molecules/SourceList/ItemPane/IItemPaneProps.ts"],"names":[],"mappings":""}
@@ -0,0 +1,36 @@
1
+ import * as React from 'react';
2
+ import { IItemPaneProps, IItemPaneState } from './IItemPaneProps';
3
+ export default class ItemPane extends React.Component<IItemPaneProps, IItemPaneState> {
4
+ private ToggleJSONCmd;
5
+ constructor(props: IItemPaneProps);
6
+ componentDidMount(): Promise<void>;
7
+ updateWebInfo(webUrl: string, listChangeOnly: boolean): Promise<void>;
8
+ /***
9
+ * d8888b. d888888b d8888b. db db d8888b. d8888b. .d8b. d888888b d88888b
10
+ * 88 `8D `88' 88 `8D 88 88 88 `8D 88 `8D d8' `8b `~~88~~' 88'
11
+ * 88 88 88 88 88 88 88 88oodD' 88 88 88ooo88 88 88ooooo
12
+ * 88 88 88 88 88 88 88 88~~~ 88 88 88~~~88 88 88~~~~~
13
+ * 88 .8D .88. 88 .8D 88b d88 88 88 .8D 88 88 88 88.
14
+ * Y8888D' Y888888P Y8888D' ~Y8888P' 88 Y8888D' YP YP YP Y88888P
15
+ *
16
+ *
17
+ */
18
+ componentDidUpdate(prevProps: IItemPaneProps): void;
19
+ render(): React.ReactElement<IItemPaneProps>;
20
+ /**
21
+ * function: getValidPropLI
22
+ *
23
+ * Created this function to resolve issue: https://github.com/mikezimm/ALVFinMan/issues/167
24
+ * @param showThisItem
25
+ * @param field
26
+ * @param idx
27
+ * @returns
28
+ */
29
+ private getValidPropLI;
30
+ private updateModernState;
31
+ private openItemNewTab;
32
+ private openThisLink;
33
+ private clickOpenInNewTab;
34
+ private _toggleJSON;
35
+ }
36
+ //# sourceMappingURL=component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../../../../src/components/molecules/SourceList/ItemPane/component.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAa/B,OAAO,EAAE,cAAc,EAAE,cAAc,EAAG,MAAM,kBAAkB,CAAC;AAsBnE,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,KAAK,CAAC,SAAS,CAAC,cAAc,EAAE,cAAc,CAAC;IAEnF,OAAO,CAAC,aAAa,CAAgF;gBAElF,KAAK,EAAC,cAAc;IAS1B,iBAAiB,IAAI,OAAO,CAAC,IAAI,CAAC;IAKlC,aAAa,CAAG,MAAM,EAAE,MAAM,EAAE,cAAc,EAAG,OAAO,GAAI,OAAO,CAAC,IAAI,CAAC;IAQpF;;;;;;;;;KASC;IAEI,kBAAkB,CAAC,SAAS,EAAE,cAAc,GAAG,IAAI;IA2DnD,MAAM,IAAI,KAAK,CAAC,YAAY,CAAC,cAAc,CAAC;IA4HnD;;;;;;;;OAQG;IAEH,OAAO,CAAC,cAAc;IA0BtB,OAAO,CAAC,iBAAiB;IAKzB,OAAO,CAAC,cAAc;IAItB,OAAO,CAAC,YAAY;IAIpB,OAAO,CAAC,iBAAiB;IAKzB,OAAO,CAAC,WAAW;CAUpB"}
@@ -0,0 +1,263 @@
1
+ import * as React from 'react';
2
+ import { Icon } from 'office-ui-fabric-react/lib/Icon';
3
+ // import * as strings from 'AlvFinManWebPartStrings';
4
+ import ReactJson from "react-json-view";
5
+ import { makeToggleJSONCmd } from '../../../atoms/Elements/ToggleJSONButton';
6
+ require('@mikezimm/fps-styles/dist/fpsDateStamp.css');
7
+ require('@mikezimm/fps-styles/dist/sourceItemPane.css');
8
+ // import { replaceHTMLEntities } from '../../../fpsReferences';
9
+ // import { sortStringArray, sortObjectArrayByStringKey, sortNumberArray, sortObjectArrayByNumberKey, sortKeysByOtherKey } from '../../../fpsReferences';
10
+ // import { divide, stubFalse } from 'lodash';
11
+ // import { makeToggleJSONCmd } from '../../../fpsReferences';
12
+ // import { getDocWiki } from './getModernContent';
13
+ // import { getModernHumanReadable } from './processModernContent';
14
+ // const consoleLineItemBuild: boolean = false;
15
+ export default class ItemPane extends React.Component {
16
+ constructor(props) {
17
+ super(props);
18
+ this.ToggleJSONCmd = makeToggleJSONCmd(this._toggleJSON.bind(this), 'Click for more details');
19
+ console.log('constructor:');
20
+ this.state = {
21
+ showPanelJSON: false,
22
+ showThisItem: this.props.item,
23
+ };
24
+ }
25
+ async componentDidMount() {
26
+ console.log('componentDidMount:');
27
+ await this.updateWebInfo('', false);
28
+ }
29
+ async updateWebInfo(webUrl, listChangeOnly) {
30
+ console.log('updateWebInfo:');
31
+ if (this.props.item && this.props.showCanvasContent1 === true) {
32
+ // getDocWiki( this.props.page , this.props.source, this.props.canvasOptions, this.props.showCanvasContent1, this.updateModernState.bind( this ) );
33
+ }
34
+ }
35
+ //
36
+ /***
37
+ * d8888b. d888888b d8888b. db db d8888b. d8888b. .d8b. d888888b d88888b
38
+ * 88 `8D `88' 88 `8D 88 88 88 `8D 88 `8D d8' `8b `~~88~~' 88'
39
+ * 88 88 88 88 88 88 88 88oodD' 88 88 88ooo88 88 88ooooo
40
+ * 88 88 88 88 88 88 88 88~~~ 88 88 88~~~88 88 88~~~~~
41
+ * 88 .8D .88. 88 .8D 88b d88 88 88 .8D 88 88 88 88.
42
+ * Y8888D' Y888888P Y8888D' ~Y8888P' 88 Y8888D' YP YP YP Y88888P
43
+ *
44
+ *
45
+ */
46
+ componentDidUpdate(prevProps) {
47
+ //Just rebuild the component
48
+ console.log('ItemPane', this.props);
49
+ // refresh any changes in these props:
50
+ const compareProps = ['refreshId', 'imageStyle', 'showJSONDetail', 'showDateStamps', 'showItemLink', 'showListLink',];
51
+ let itemRefreshed = false;
52
+ compareProps.map(testProp => {
53
+ // here casting testProp as a valid key because casting as any throws a linting error
54
+ if (itemRefreshed === false && this.props[testProp] !== prevProps[testProp]) {
55
+ itemRefreshed = true;
56
+ this.setState({ showThisItem: this.props.item });
57
+ }
58
+ });
59
+ const compareStringy = ['canvasOptions',];
60
+ compareStringy.map(testProp => {
61
+ // here casting testProp as a valid key because casting as any throws a linting error
62
+ if (itemRefreshed === false && JSON.stringify(this.props[testProp]) !== JSON.stringify(prevProps[testProp])) {
63
+ itemRefreshed = true;
64
+ this.setState({ showThisItem: this.props.item });
65
+ }
66
+ });
67
+ // if ( this.props.refreshId !== prevProps.refreshId ) {
68
+ // this.setState({ showThisItem: this.props.item });
69
+ // // } else if ( this.props.imageStyle !== prevProps.imageStyle ) {
70
+ // // this.setState({ showThisItem: this.props.item });
71
+ // // eslint-disable-next-line dot-notation
72
+ // } else if ( this.props[ 'imageStyle' ] !== prevProps[ 'imageStyle' ] ) {
73
+ // this.setState({ showThisItem: this.props.item });
74
+ // } else if ( JSON.stringify( this.props.canvasOptions) !== JSON.stringify( prevProps.canvasOptions ) ) {
75
+ // this.setState({ showThisItem: this.props.item, });
76
+ // } else if ( this.props.item === null ) {
77
+ // //Do nothing if page is null
78
+ // } else if ( this.props.item.ID !== prevProps.item.ID ) {
79
+ // this.setState({ showThisItem: this.props.item, });
80
+ // } else if ( this.props.showJSONDetail !== prevProps.showJSONDetail ) {
81
+ // this.setState({ showThisItem: this.props.item, });
82
+ // } else if ( this.props.showDateStamps !== prevProps.showDateStamps ) {
83
+ // this.setState({ showThisItem: this.props.item, });
84
+ // } else if ( this.props.showItemLink !== prevProps.showItemLink ) {
85
+ // this.setState({ showThisItem: this.props.item, });
86
+ // } else if ( this.props.showListLink !== prevProps.showListLink ) {
87
+ // this.setState({ showThisItem: this.props.item, });
88
+ // }
89
+ }
90
+ render() {
91
+ const { primarySource, topButtons, debugMode, showCanvasContent1, showJSONDetail, showDateStamps, showItemLink, showListLink } = this.props; // eslint-disable-line @typescript-eslint/no-unused-vars
92
+ const { showThisItem, } = this.state;
93
+ if (!showThisItem) {
94
+ // const FetchingSpinner = <Spinner size={SpinnerSize.large} label={"Fetching Page ..."} style={{ padding: 30 }} />;
95
+ // return ( <div>{ FetchingSpinner }</div> );
96
+ return (React.createElement("div", null));
97
+ }
98
+ else {
99
+ const gotoListLink = showListLink === false || !primarySource.webRelativeLink ? null : React.createElement("div", { className: ['listLink', 'goToLink'].join(' '), onClick: () => { window.open(`${primarySource.webUrl}${primarySource.webRelativeLink}`, '_blank'); } },
100
+ "Open list ",
101
+ React.createElement(Icon, { iconName: 'OpenInNewTab' }));
102
+ //Go directly to file if it's a file, else go to list item
103
+ const viewItemLink = `${showThisItem.FileRef ? showThisItem.FileRef : primarySource.viewItemLink.replace('{{item.ID}}', showThisItem.ID)} `;
104
+ const gotoItemLink = showItemLink === false || !viewItemLink ? undefined : React.createElement("div", { style: { cursor: 'pointer' }, onClick: () => { window.open(viewItemLink, '_blank'); } },
105
+ "Open item ",
106
+ React.createElement(Icon, { iconName: 'OpenInNewTab' }));
107
+ const debugContent = this.props.debugMode !== true ? null : React.createElement("div", { style: { cursor: 'default', marginLeft: '20px' } },
108
+ "App in debugMode - Change in Web Part Properties - Page Preferences. ",
109
+ React.createElement("b", null,
110
+ React.createElement("em", null, "Currently in ItemPane")));
111
+ let panelTitle = 'Unknown Title';
112
+ if (showThisItem.Title) {
113
+ panelTitle = showThisItem.Title;
114
+ }
115
+ else if (showThisItem.Title0) {
116
+ panelTitle = showThisItem.Title0;
117
+ }
118
+ else if (showThisItem.FileLeafRef) {
119
+ panelTitle = showThisItem.FileLeafRef;
120
+ }
121
+ const viewItemElement = !viewItemLink || showItemLink === false ? undefined :
122
+ React.createElement(React.Fragment, null,
123
+ gotoItemLink,
124
+ gotoListLink);
125
+ const dateStampes = showDateStamps === false ? undefined :
126
+ React.createElement(React.Fragment, null,
127
+ React.createElement("div", { className: 'fps-date-stamp' },
128
+ React.createElement("div", null, "Created"),
129
+ " ",
130
+ React.createElement("div", null, showThisItem.createdLoc),
131
+ " ",
132
+ React.createElement("div", null, showThisItem['Author/Title'])),
133
+ React.createElement("div", { className: 'fps-date-stamp' },
134
+ React.createElement("div", null, "Modified"),
135
+ " ",
136
+ React.createElement("div", null, showThisItem.modifiedLoc),
137
+ " ",
138
+ React.createElement("div", null, showThisItem['Editor/Title'])));
139
+ const panelHeading = React.createElement("div", { className: 'supPanelHeader' },
140
+ React.createElement("h2", null, panelTitle),
141
+ dateStampes,
142
+ React.createElement("h3", { style: { display: 'flex', justifyContent: 'flex-start', alignItems: 'center', paddingBottom: '20px' } },
143
+ React.createElement("div", { style: { paddingRight: '30px' } }, showThisItem.ID),
144
+ viewItemElement));
145
+ const headerComponent = React.createElement("div", null,
146
+ debugContent,
147
+ panelHeading);
148
+ const fileEmbed = !showThisItem.ServerRedirectedEmbedUrl ? null : React.createElement("iframe", { src: showThisItem.ServerRedirectedEmbedUrl, height: '350px', width: '100%', style: { paddingTop: '20px' } });
149
+ const searchProps = JSON.parse(JSON.stringify(primarySource.searchProps));
150
+ console.log('selectThese - searchProps', searchProps);
151
+ const searchPropsList = primarySource && searchProps && searchProps.length > 0 ?
152
+ React.createElement("ul", null, searchProps.map((field, idx) => {
153
+ // https://github.com/mikezimm/ALVFinMan/issues/167
154
+ return this.getValidPropLI(showThisItem, field, idx);
155
+ })) : React.createElement("div", null, "There are no Searched properties.");
156
+ //Created this ling hand instead of filter after the LinkColumn issue.
157
+ //Filter may work but I've had it on this one trying to figure it out.
158
+ const selectThese = [];
159
+ primarySource.selectThese.map((selectProp) => {
160
+ if (primarySource.searchProps.indexOf(selectProp) < 0)
161
+ selectThese.push(selectProp);
162
+ });
163
+ console.log('selectThese - selectThese', selectThese);
164
+ const selectTheseList = primarySource && selectThese && selectThese.length > 0 ?
165
+ React.createElement("ul", null, selectThese.map((field, idx) => {
166
+ // https://github.com/mikezimm/ALVFinMan/issues/167
167
+ return this.getValidPropLI(showThisItem, field, idx);
168
+ })) : React.createElement("div", null, "There are no Selected properties.");
169
+ const itemContent = React.createElement("div", null,
170
+ React.createElement("div", { className: 'source-itemPane-properties' },
171
+ React.createElement("h3", null, "Searched Properties"),
172
+ searchPropsList),
173
+ React.createElement("div", { className: 'source-itemPane-properties' },
174
+ React.createElement("h3", null, "Selected Properties"),
175
+ selectTheseList));
176
+ const jsonContent = showJSONDetail === false || this.state.showPanelJSON !== true ? undefined : React.createElement("div", null,
177
+ React.createElement(ReactJson, { src: showThisItem, name: 'Summary', collapsed: false, displayDataTypes: true, displayObjectSize: true, enableClipboard: true, style: { padding: '20px 0px' } }));
178
+ // const fileEmbed = !showThisItem || !showThisItem.ServerRedirectedEmbedUrl ? null : <iframe src={ showThisItem.ServerRedirectedEmbedUrl } height='350px' width='100%' style={{paddingTop: '20px' }}></iframe>;
179
+ return (React.createElement("div", { className: ['source-itemPane', ''].join(' ') },
180
+ headerComponent,
181
+ this.props.customElement1 ? this.props.customElement1 : undefined,
182
+ fileEmbed,
183
+ itemContent,
184
+ this.props.customElement2 ? this.props.customElement2 : undefined,
185
+ this.ToggleJSONCmd,
186
+ jsonContent));
187
+ }
188
+ }
189
+ /**
190
+ * function: getValidPropLI
191
+ *
192
+ * Created this function to resolve issue: https://github.com/mikezimm/ALVFinMan/issues/167
193
+ * @param showThisItem
194
+ * @param field
195
+ * @param idx
196
+ * @returns
197
+ */
198
+ getValidPropLI(showThisItem, field, idx) {
199
+ var _a;
200
+ console.log('field', field, typeof showThisItem[field], JSON.stringify(showThisItem[field]));
201
+ const isLink = ((_a = showThisItem[field]) === null || _a === void 0 ? void 0 : _a.Url) ? true : false;
202
+ const isObject = typeof showThisItem[field] === 'object' ? true : false;
203
+ const isRich = typeof showThisItem[field] === 'string' && showThisItem[field].indexOf(`<div class="ExternalClass`) === 0 ? true : false;
204
+ if (isRich === true) {
205
+ return React.createElement("li", { key: idx },
206
+ React.createElement("div", null,
207
+ field,
208
+ ":"),
209
+ " ",
210
+ React.createElement("div", { dangerouslySetInnerHTML: { __html: showThisItem[field] } }));
211
+ }
212
+ else if (isLink === true) {
213
+ return React.createElement("li", { key: idx },
214
+ React.createElement("div", null,
215
+ field,
216
+ ":"),
217
+ " ",
218
+ React.createElement("div", { style: { cursor: 'pointer', fontSize: 'larger' }, onClick: () => window.open(showThisItem[field].Url, '_blank') },
219
+ showThisItem[field].Description,
220
+ React.createElement(Icon, { style: { marginLeft: '30px' }, iconName: 'OpenInNewTab' })));
221
+ }
222
+ else if (isObject === true) {
223
+ const obj = JSON.stringify(showThisItem[field]);
224
+ return React.createElement("li", { key: idx },
225
+ React.createElement("div", null,
226
+ field,
227
+ ":"),
228
+ " ",
229
+ React.createElement("div", null, obj));
230
+ }
231
+ else {
232
+ return React.createElement("li", { key: idx },
233
+ React.createElement("div", null,
234
+ field,
235
+ ":"),
236
+ " ",
237
+ React.createElement("div", null, showThisItem[field]));
238
+ }
239
+ }
240
+ //getDocWiki( item: IPagesContent, source: ISourcePropsFM, canvasOptions: ICanvasContentOptions, callBack: any )
241
+ updateModernState(item) {
242
+ this.setState({
243
+ showThisItem: item
244
+ });
245
+ }
246
+ openItemNewTab(item) {
247
+ window.open(item.File.ServerRelativeUrl, '_blank');
248
+ }
249
+ openThisLink(link) {
250
+ window.open(link, '_blank');
251
+ }
252
+ clickOpenInNewTab(href) {
253
+ console.log('clickOpenInNewTab:', href);
254
+ window.open(href, '_blank');
255
+ }
256
+ _toggleJSON() {
257
+ const newState = this.state.showPanelJSON === true ? false : true;
258
+ const result = this.state.showThisItem;
259
+ // result = getModernHumanReadable( result );
260
+ this.setState({ showThisItem: result, showPanelJSON: newState });
261
+ }
262
+ }
263
+ //# sourceMappingURL=component.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"component.js","sourceRoot":"","sources":["../../../../../src/components/molecules/SourceList/ItemPane/component.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAE,IAAI,EAAE,MAAM,iCAAiC,CAAC;AAavD,sDAAsD;AAEtD,OAAO,SAAS,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAC;AAI7E,OAAO,CAAC,4CAA4C,CAAC,CAAC;AACtD,OAAO,CAAC,8CAA8C,CAAC,CAAC;AAExD,gEAAgE;AAChE,yJAAyJ;AAEzJ,8CAA8C;AAC9C,8DAA8D;AAC9D,mDAAmD;AACnD,mEAAmE;AAEnE,+CAA+C;AAE/C,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,KAAK,CAAC,SAAyC;IAInF,YAAmB,KAAoB;QACrC,KAAK,CAAC,KAAK,CAAC,CAAC;QAHP,kBAAa,GAAG,iBAAiB,CAAE,IAAI,CAAC,WAAW,CAAC,IAAI,CAAE,IAAI,CAAE,EAAE,wBAAwB,CAAE,CAAC;QAInG,OAAO,CAAC,GAAG,CAAC,cAAc,CAAK,CAAC;QAChC,IAAI,CAAC,KAAK,GAAG;YACX,aAAa,EAAE,KAAK;YACpB,YAAY,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI;SAC9B,CAAC;IACJ,CAAC;IAEM,KAAK,CAAC,iBAAiB;QAC5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,CAAE;SAEvF;IAEH,CAAC;IACD,iHAAiH;IACzG,iBAAiB,CAAE,IAAoB;QAC7C,IAAI,CAAC,QAAQ,CAAC;YACZ,YAAY,EAAE,IAAI;SAAE,CAAC,CAAC;IAC1B,CAAC;IAEO,cAAc,CAAE,IAAmB;QACzC,MAAM,CAAC,IAAI,CAAE,IAAI,CAAC,IAAI,CAAC,iBAAiB,EAAG,QAAQ,CAAE,CAAC;IACxD,CAAC;IAEO,YAAY,CAAE,IAAW;QAC/B,MAAM,CAAC,IAAI,CAAE,IAAI,EAAG,QAAQ,CAAE,CAAC;IACjC,CAAC;IAEO,iBAAiB,CAAE,IAAY;QACrC,OAAO,CAAC,GAAG,CAAC,oBAAoB,EAAE,IAAI,CAAE,CAAC;QACzC,MAAM,CAAC,IAAI,CAAE,IAAI,EAAG,QAAQ,CAAE,CAAC;IACjC,CAAC;IAEO,WAAW;QACjB,MAAM,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,KAAK,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC;QAElE,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC;QACvC,6CAA6C;QAE7C,IAAI,CAAC,QAAQ,CAAE,EAAE,YAAY,EAAE,MAAM,EAAG,aAAa,EAAE,QAAQ,EAAE,CAAC,CAAC;IACrE,CAAC;CAGF"}
@@ -1,3 +1,15 @@
1
1
  export declare const RegexHashNumber: RegExp;
2
2
  export declare const RegexXMLOpenProp: RegExp;
3
+ /**
4
+ * Common Regex examples
5
+ */
6
+ export declare const RegexSpecial: RegExp;
7
+ export declare const RegexMathOps: RegExp;
8
+ export declare const RegexSquarBkt: RegExp;
9
+ export declare const RegexCurleys: RegExp;
10
+ export declare const RegexParenth: RegExp;
11
+ export declare const RegexSlashes: RegExp;
12
+ export declare const RegexQuotes: RegExp;
13
+ export declare const RegexSpaces: RegExp;
14
+ export declare const RegexWords: RegExp;
3
15
  //# sourceMappingURL=constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/logic/Regex/constants.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,eAAe,QAAa,CAAC;AAI1C,eAAO,MAAM,gBAAgB,QAAgB,CAAC"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/logic/Regex/constants.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,eAAe,QAAa,CAAC;AAI1C,eAAO,MAAM,gBAAgB,QAAgB,CAAC;AAM9C;;GAEG;AAGH,eAAO,MAAM,YAAY,QAA8B,CAAC;AAExD,eAAO,MAAM,YAAY,QAAe,CAAC;AAEzC,eAAO,MAAM,aAAa,QAAY,CAAC;AAEvC,eAAO,MAAM,YAAY,QAAW,CAAC;AAErC,eAAO,MAAM,YAAY,QAAW,CAAC;AAErC,eAAO,MAAM,YAAY,QAAa,CAAC;AAEvC,eAAO,MAAM,WAAW,QAAU,CAAC;AAEnC,eAAO,MAAM,WAAW,QAAW,CAAC;AAEpC,eAAO,MAAM,UAAU,QAAmB,CAAA"}
@@ -7,4 +7,17 @@ export const RegexXMLOpenProp = /[\"] [A-Z]/g;
7
7
  //Used in /..Elements/markdown
8
8
  // Moved this to src\logic\Strings\splitHash.ts where it is used
9
9
  // export type INullOrStringArray = null | string[];
10
+ /**
11
+ * Common Regex examples
12
+ */
13
+ // Replace most common special characters
14
+ export const RegexSpecial = /[.,;:?|=~!&^{}$%+_[\]-]+/g;
15
+ export const RegexMathOps = /[+*\/=-]+/g; // Replace basic math opts [ ]
16
+ export const RegexSquarBkt = /[[\]]+/g; // Replace brackets [ ]
17
+ export const RegexCurleys = /[{}]+/g; // Replace parentheses { }
18
+ export const RegexParenth = /[()]+/g; // Replace parentheses ( )
19
+ export const RegexSlashes = /[/\\]+/g; // Replace slashes / \
20
+ export const RegexQuotes = /[']+/g; // Replace quotes
21
+ export const RegexSpaces = /\s\s+/g; // Replace multiple spaces with just one
22
+ export const RegexWords = /\b([a-z]+)\b/gi; // Used to split a string by word boundaries only using a-z any case
10
23
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/logic/Regex/constants.ts"],"names":[],"mappings":"AACA,+DAA+D;AAE/D,kEAAkE;AAClE,MAAM,CAAC,MAAM,eAAe,GAAG,UAAU,CAAC,CAAG,sCAAsC;AAEnF,qGAAqG;AACrG,iEAAiE;AACjE,MAAM,CAAC,MAAM,gBAAgB,GAAG,aAAa,CAAC;AAE9C,8BAA8B;AAC9B,gEAAgE;AAChE,oDAAoD"}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/logic/Regex/constants.ts"],"names":[],"mappings":"AACA,+DAA+D;AAE/D,kEAAkE;AAClE,MAAM,CAAC,MAAM,eAAe,GAAG,UAAU,CAAC,CAAG,sCAAsC;AAEnF,qGAAqG;AACrG,iEAAiE;AACjE,MAAM,CAAC,MAAM,gBAAgB,GAAG,aAAa,CAAC;AAE9C,8BAA8B;AAC9B,gEAAgE;AAChE,oDAAoD;AAEpD;;GAEG;AAEH,yCAAyC;AACzC,MAAM,CAAC,MAAM,YAAY,GAAG,2BAA2B,CAAC;AAExD,MAAM,CAAC,MAAM,YAAY,GAAG,YAAY,CAAC,CAAG,+BAA+B;AAE3E,MAAM,CAAC,MAAM,aAAa,GAAG,SAAS,CAAC,CAAG,wBAAwB;AAElE,MAAM,CAAC,MAAM,YAAY,GAAG,QAAQ,CAAC,CAAK,2BAA2B;AAErE,MAAM,CAAC,MAAM,YAAY,GAAG,QAAQ,CAAC,CAAK,2BAA2B;AAErE,MAAM,CAAC,MAAM,YAAY,GAAI,SAAS,CAAC,CAAG,sBAAsB;AAEhE,MAAM,CAAC,MAAM,WAAW,GAAG,OAAO,CAAC,CAAO,iBAAiB;AAE3D,MAAM,CAAC,MAAM,WAAW,GAAG,QAAQ,CAAC,CAAM,wCAAwC;AAElF,MAAM,CAAC,MAAM,UAAU,GAAG,gBAAgB,CAAA,CAAC,oEAAoE"}