@aehrc/smart-forms-renderer 0.44.2 → 0.44.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/components/FormComponents/CustomComponent.d.ts +9 -0
- package/lib/components/FormComponents/CustomComponent.js +31 -0
- package/lib/components/FormComponents/CustomComponent.js.map +1 -0
- package/lib/components/FormComponents/CustomComponentWrapper.d.ts +1 -0
- package/lib/components/FormComponents/CustomComponentWrapper.js +40 -0
- package/lib/components/FormComponents/CustomComponentWrapper.js.map +1 -0
- package/lib/components/FormComponents/DecimalItem/index.d.ts +1 -0
- package/lib/components/FormComponents/DecimalItem/index.js +18 -0
- package/lib/components/FormComponents/DecimalItem/index.js.map +1 -0
- package/lib/components/FormComponents/GroupItem/Collapsible.d.ts +3 -0
- package/lib/components/FormComponents/GroupItem/Collapsible.js +6 -0
- package/lib/components/FormComponents/GroupItem/Collapsible.js.map +1 -0
- package/lib/components/FormComponents/GroupItem/GroupAccordion.d.ts +0 -0
- package/lib/components/FormComponents/GroupItem/GroupAccordion.js +2 -0
- package/lib/components/FormComponents/GroupItem/GroupAccordion.js.map +1 -0
- package/lib/components/FormComponents/ItemParts/FlyoverItem.d.ts +6 -0
- package/lib/components/FormComponents/ItemParts/FlyoverItem.js +45 -0
- package/lib/components/FormComponents/ItemParts/FlyoverItem.js.map +1 -0
- package/lib/components/FormComponents/ItemParts/index.d.ts +1 -0
- package/lib/components/FormComponents/ItemParts/index.js +18 -0
- package/lib/components/FormComponents/ItemParts/index.js.map +1 -0
- package/lib/components/FormComponents/StringItem/index.d.ts +1 -0
- package/lib/components/FormComponents/StringItem/index.js +18 -0
- package/lib/components/FormComponents/StringItem/index.js.map +1 -0
- package/lib/components/Pages/SingleItemPaginated.d.ts +19 -0
- package/lib/components/Pages/SingleItemPaginated.js +7 -0
- package/lib/components/Pages/SingleItemPaginated.js.map +1 -0
- package/lib/components/Renderer/FormBodyPaginated.d.ts +9 -0
- package/lib/components/Renderer/FormBodyPaginated.js +49 -0
- package/lib/components/Renderer/FormBodyPaginated.js.map +1 -0
- package/lib/components/Renderer/PageItem.d.ts +9 -0
- package/lib/components/Renderer/PageItem.js +68 -0
- package/lib/components/Renderer/PageItem.js.map +1 -0
- package/lib/hooks/useInitialiseGroupTable.d.ts +4 -0
- package/lib/hooks/useInitialiseGroupTable.js +36 -0
- package/lib/hooks/useInitialiseGroupTable.js.map +1 -0
- package/lib/hooks/useNumberInput.d.ts +3 -0
- package/lib/hooks/useNumberInput.js +31 -0
- package/lib/hooks/useNumberInput.js.map +1 -0
- package/lib/hooks/useRepeatGroups.d.ts +4 -0
- package/lib/hooks/useRepeatGroups.js +34 -0
- package/lib/hooks/useRepeatGroups.js.map +1 -0
- package/lib/hooks/useStringInput.d.ts +3 -0
- package/lib/hooks/useStringInput.js +32 -0
- package/lib/hooks/useStringInput.js.map +1 -0
- package/lib/interfaces/customComponent.d.ts +9 -0
- package/lib/interfaces/customComponent.interface.d.ts +9 -0
- package/lib/interfaces/customComponent.interface.js +18 -0
- package/lib/interfaces/customComponent.interface.js.map +1 -0
- package/lib/interfaces/customComponent.js +18 -0
- package/lib/interfaces/customComponent.js.map +1 -0
- package/lib/interfaces/customOverrideComponent.interface.d.ts +9 -0
- package/lib/interfaces/customOverrideComponent.interface.js +18 -0
- package/lib/interfaces/customOverrideComponent.interface.js.map +1 -0
- package/lib/interfaces/overrideComponent.interface.d.ts +12 -0
- package/lib/interfaces/overrideComponent.interface.js +18 -0
- package/lib/interfaces/overrideComponent.interface.js.map +1 -0
- package/lib/interfaces/qItemOverrideComponent.interface.d.ts +9 -0
- package/lib/interfaces/qItemOverrideComponent.interface.js +18 -0
- package/lib/interfaces/qItemOverrideComponent.interface.js.map +1 -0
- package/lib/stores/rendererStylingStore.d.ts +31 -0
- package/lib/stores/rendererStylingStore.js +40 -0
- package/lib/stores/rendererStylingStore.js.map +1 -0
- package/lib/stores/stylingStore.d.ts +23 -0
- package/lib/stores/stylingStore.js +27 -0
- package/lib/stores/stylingStore.js.map +1 -0
- package/lib/stories/storybookWrappers/iframeResizerChild.d.ts +1 -0
- package/lib/stories/storybookWrappers/iframeResizerChild.js +849 -0
- package/lib/stories/storybookWrappers/iframeResizerChild.js.map +1 -0
- package/lib/utils/customComponent.d.ts +9 -0
- package/lib/utils/customComponent.js +18 -0
- package/lib/utils/customComponent.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { useEffect, useState } from 'react';
|
|
18
|
+
// The purpose of this hook to sync the string state from external changes i.e. re-population changes etc.
|
|
19
|
+
function useStringInput(valueFromProps) {
|
|
20
|
+
const [input, setInput] = useState(valueFromProps);
|
|
21
|
+
useEffect(() => {
|
|
22
|
+
if (input !== valueFromProps) {
|
|
23
|
+
setInput(valueFromProps);
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
// Only trigger this effect if prop value changes
|
|
27
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
28
|
+
[valueFromProps]);
|
|
29
|
+
return [input, setInput];
|
|
30
|
+
}
|
|
31
|
+
export default useStringInput;
|
|
32
|
+
//# sourceMappingURL=useStringInput.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useStringInput.js","sourceRoot":"","sources":["../../src/hooks/useStringInput.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAGH,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAE5C,0GAA0G;AAC1G,SAAS,cAAc,CAAC,cAAsB;IAC5C,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,QAAQ,CAAC,cAAc,CAAC,CAAC;IAEnD,SAAS,CACP,GAAG,EAAE;QACH,IAAI,KAAK,KAAK,cAAc,EAAE;YAC5B,QAAQ,CAAC,cAAc,CAAC,CAAC;SAC1B;IACH,CAAC;IACD,iDAAiD;IACjD,uDAAuD;IACvD,CAAC,cAAc,CAAC,CACjB,CAAC;IAEF,OAAO,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;AAC3B,CAAC;AAED,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { QuestionnaireItem, type QuestionnaireResponseItem } from 'fhir/r4';
|
|
2
|
+
export interface CustomComponentProps {
|
|
3
|
+
qItem: QuestionnaireItem;
|
|
4
|
+
qrItem: QuestionnaireResponseItem | null;
|
|
5
|
+
isRepeated: boolean;
|
|
6
|
+
isTabled: boolean;
|
|
7
|
+
parentIsReadOnly?: boolean;
|
|
8
|
+
onQrItemChange: (qrItem: QuestionnaireResponseItem) => unknown;
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { QuestionnaireItem, type QuestionnaireResponseItem } from 'fhir/r4';
|
|
2
|
+
export interface CustomComponentProps {
|
|
3
|
+
qItem: QuestionnaireItem;
|
|
4
|
+
qrItem: QuestionnaireResponseItem | null;
|
|
5
|
+
isRepeated: boolean;
|
|
6
|
+
isTabled: boolean;
|
|
7
|
+
parentIsReadOnly?: boolean;
|
|
8
|
+
onQrItemChange: (qrItem: QuestionnaireResponseItem) => unknown;
|
|
9
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=customComponent.interface.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customComponent.interface.js","sourceRoot":"","sources":["../../src/interfaces/customComponent.interface.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=customComponent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customComponent.js","sourceRoot":"","sources":["../../src/interfaces/customComponent.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { QuestionnaireItem, type QuestionnaireResponseItem } from 'fhir/r4';
|
|
2
|
+
export interface CustomOverrideComponentProps {
|
|
3
|
+
qItem: QuestionnaireItem;
|
|
4
|
+
qrItem: QuestionnaireResponseItem | null;
|
|
5
|
+
isRepeated: boolean;
|
|
6
|
+
isTabled: boolean;
|
|
7
|
+
parentIsReadOnly?: boolean;
|
|
8
|
+
onQrItemChange: (qrItem: QuestionnaireResponseItem) => unknown;
|
|
9
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=customOverrideComponent.interface.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customOverrideComponent.interface.js","sourceRoot":"","sources":["../../src/interfaces/customOverrideComponent.interface.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { QuestionnaireItem, QuestionnaireResponseItem } from 'fhir/r4';
|
|
2
|
+
export interface QItemOverrideComponentProps {
|
|
3
|
+
qItem: QuestionnaireItem;
|
|
4
|
+
qrItem: QuestionnaireResponseItem | null;
|
|
5
|
+
isRepeated: boolean;
|
|
6
|
+
isTabled: boolean;
|
|
7
|
+
parentIsReadOnly?: boolean;
|
|
8
|
+
onQrItemChange: (qrItem: QuestionnaireResponseItem) => unknown;
|
|
9
|
+
}
|
|
10
|
+
export interface SdcUiOverrideComponentProps {
|
|
11
|
+
displayText: string;
|
|
12
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=overrideComponent.interface.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"overrideComponent.interface.js","sourceRoot":"","sources":["../../src/interfaces/overrideComponent.interface.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { QuestionnaireItem, type QuestionnaireResponseItem } from 'fhir/r4';
|
|
2
|
+
export interface QItemOverrideComponentProps {
|
|
3
|
+
qItem: QuestionnaireItem;
|
|
4
|
+
qrItem: QuestionnaireResponseItem | null;
|
|
5
|
+
isRepeated: boolean;
|
|
6
|
+
isTabled: boolean;
|
|
7
|
+
parentIsReadOnly?: boolean;
|
|
8
|
+
onQrItemChange: (qrItem: QuestionnaireResponseItem) => unknown;
|
|
9
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=qItemOverrideComponent.interface.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"qItemOverrideComponent.interface.js","sourceRoot":"","sources":["../../src/interfaces/qItemOverrideComponent.interface.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export interface RendererStyling {
|
|
2
|
+
itemLabelFontWeight?: '100' | '200' | '300' | '400' | '500' | '600' | '700' | '800' | '900' | 'default';
|
|
3
|
+
enableWhenAsReadOnly?: boolean | 'non-group';
|
|
4
|
+
disablePageCardView?: boolean;
|
|
5
|
+
disablePageButtons?: boolean;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* RendererStylingStore properties and methods
|
|
9
|
+
*
|
|
10
|
+
* @author Sean Fong
|
|
11
|
+
*/
|
|
12
|
+
export interface RendererStylingStoreType {
|
|
13
|
+
itemLabelFontWeight: '100' | '200' | '300' | '400' | '500' | '600' | '700' | '800' | '900' | 'default';
|
|
14
|
+
enableWhenAsReadOnly: boolean | 'non-group';
|
|
15
|
+
disablePageCardView: boolean;
|
|
16
|
+
disablePageButtons: boolean;
|
|
17
|
+
setRendererStyling: (params: RendererStyling) => void;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* @author Sean Fong
|
|
21
|
+
*/
|
|
22
|
+
export declare const rendererStylingStore: import("zustand/vanilla").StoreApi<RendererStylingStoreType>;
|
|
23
|
+
export declare const useRendererStylingStore: import("zustand/vanilla").StoreApi<RendererStylingStoreType> & {
|
|
24
|
+
use: {
|
|
25
|
+
itemLabelFontWeight: () => "500" | "800" | "600" | "default" | "100" | "200" | "300" | "400" | "700" | "900";
|
|
26
|
+
enableWhenAsReadOnly: () => boolean | "non-group";
|
|
27
|
+
disablePageCardView: () => boolean;
|
|
28
|
+
disablePageButtons: () => boolean;
|
|
29
|
+
setRendererStyling: () => (params: RendererStyling) => void;
|
|
30
|
+
};
|
|
31
|
+
};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { createStore } from 'zustand/vanilla';
|
|
18
|
+
import { createSelectors } from './selector';
|
|
19
|
+
/**
|
|
20
|
+
* @author Sean Fong
|
|
21
|
+
*/
|
|
22
|
+
export const rendererStylingStore = createStore()((set) => ({
|
|
23
|
+
itemLabelFontWeight: 'default',
|
|
24
|
+
enableWhenAsReadOnly: false,
|
|
25
|
+
disablePageCardView: false,
|
|
26
|
+
disablePageButtons: false,
|
|
27
|
+
setRendererStyling: (params) => {
|
|
28
|
+
set(() => {
|
|
29
|
+
var _a, _b, _c, _d;
|
|
30
|
+
return ({
|
|
31
|
+
itemLabelFontWeight: (_a = params.itemLabelFontWeight) !== null && _a !== void 0 ? _a : 'default',
|
|
32
|
+
enableWhenAsReadOnly: (_b = params.enableWhenAsReadOnly) !== null && _b !== void 0 ? _b : false,
|
|
33
|
+
disablePageCardView: (_c = params.disablePageCardView) !== null && _c !== void 0 ? _c : false,
|
|
34
|
+
disablePageButtons: (_d = params.disablePageButtons) !== null && _d !== void 0 ? _d : false
|
|
35
|
+
});
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
}));
|
|
39
|
+
export const useRendererStylingStore = createSelectors(rendererStylingStore);
|
|
40
|
+
//# sourceMappingURL=rendererStylingStore.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rendererStylingStore.js","sourceRoot":"","sources":["../../src/stores/rendererStylingStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AA0C7C;;GAEG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,WAAW,EAA4B,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;IACpF,mBAAmB,EAAE,SAAS;IAC9B,oBAAoB,EAAE,KAAK;IAC3B,mBAAmB,EAAE,KAAK;IAC1B,kBAAkB,EAAE,KAAK;IACzB,kBAAkB,EAAE,CAAC,MAAuB,EAAE,EAAE;QAC9C,GAAG,CAAC,GAAG,EAAE;;YAAC,OAAA,CAAC;gBACT,mBAAmB,EAAE,MAAA,MAAM,CAAC,mBAAmB,mCAAI,SAAS;gBAC5D,oBAAoB,EAAE,MAAA,MAAM,CAAC,oBAAoB,mCAAI,KAAK;gBAC1D,mBAAmB,EAAE,MAAA,MAAM,CAAC,mBAAmB,mCAAI,KAAK;gBACxD,kBAAkB,EAAE,MAAA,MAAM,CAAC,kBAAkB,mCAAI,KAAK;aACvD,CAAC,CAAA;SAAA,CAAC,CAAC;IACN,CAAC;CACF,CAAC,CAAC,CAAC;AAEJ,MAAM,CAAC,MAAM,uBAAuB,GAAG,eAAe,CAAC,oBAAoB,CAAC,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
interface RendererStyling {
|
|
2
|
+
itemLabelIsBold: boolean;
|
|
3
|
+
}
|
|
4
|
+
/**
|
|
5
|
+
* RendererStylingStore properties and methods
|
|
6
|
+
*
|
|
7
|
+
* @author Sean Fong
|
|
8
|
+
*/
|
|
9
|
+
export interface RendererStylingStoreType {
|
|
10
|
+
itemLabelIsBold: boolean;
|
|
11
|
+
setRendererStyling: (params: RendererStyling) => void;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* @author Sean Fong
|
|
15
|
+
*/
|
|
16
|
+
export declare const rendererStylingStore: import("zustand/vanilla").StoreApi<RendererStylingStoreType>;
|
|
17
|
+
export declare const useRendererStylingStore: import("zustand/vanilla").StoreApi<RendererStylingStoreType> & {
|
|
18
|
+
use: {
|
|
19
|
+
itemLabelIsBold: () => boolean;
|
|
20
|
+
setRendererStyling: () => (params: RendererStyling) => void;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2024 Commonwealth Scientific and Industrial Research
|
|
3
|
+
* Organisation (CSIRO) ABN 41 687 119 230.
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { createStore } from 'zustand/vanilla';
|
|
18
|
+
import { createSelectors } from './selector';
|
|
19
|
+
/**
|
|
20
|
+
* @author Sean Fong
|
|
21
|
+
*/
|
|
22
|
+
export const rendererStylingStore = createStore()((set) => ({
|
|
23
|
+
itemLabelIsBold: false,
|
|
24
|
+
setRendererStyling: (params) => set(() => ({ itemLabelIsBold: (params.itemLabelIsBold = false) }))
|
|
25
|
+
}));
|
|
26
|
+
export const useRendererStylingStore = createSelectors(rendererStylingStore);
|
|
27
|
+
//# sourceMappingURL=stylingStore.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stylingStore.js","sourceRoot":"","sources":["../../src/stores/stylingStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAgB7C;;GAEG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,WAAW,EAA4B,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;IACpF,eAAe,EAAE,KAAK;IACtB,kBAAkB,EAAE,CAAC,MAAuB,EAAE,EAAE,CAC9C,GAAG,CAAC,GAAG,EAAE,CAAC,CAAC,EAAE,eAAe,EAAE,CAAC,MAAM,CAAC,eAAe,GAAG,KAAK,CAAC,EAAE,CAAC,CAAC;CACrE,CAAC,CAAC,CAAC;AAEJ,MAAM,CAAC,MAAM,uBAAuB,GAAG,eAAe,CAAC,oBAAoB,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export function id(x: any): any;
|