@sphereon/ui-components.ssi-react 0.4.1-unstable.84 → 0.4.1-unstable.86
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/dist/components/fields/JSONForms/ColorPickerControl/index.d.ts +5 -0
- package/dist/components/fields/JSONForms/ColorPickerControl/index.js +22 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -1
- package/dist/renders/jsonFormsRenders.js +2 -0
- package/dist/styles/css/tailwind.css +6 -0
- package/dist/types/jsonForms/index.d.ts +2 -1
- package/dist/types/jsonForms/index.js +2 -1
- package/package.json +15 -14
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { optionIs, rankWith } from '@jsonforms/core';
|
|
3
|
+
import { withJsonFormsControlProps } from '@jsonforms/react';
|
|
4
|
+
import { MuiColorInput, MuiColorInputButton } from 'mui-color-input';
|
|
5
|
+
import { JsonFormsCustomControlKey } from '../../../../types';
|
|
6
|
+
const ColorPickerControl = (props) => {
|
|
7
|
+
const { data = 'var(--color-aqua-500)', handleChange, path, format = 'hex', isAlphaHidden = true } = props;
|
|
8
|
+
const onValueChange = async (value) => {
|
|
9
|
+
handleChange(path, value);
|
|
10
|
+
};
|
|
11
|
+
const getAdornmentElement = (props) => {
|
|
12
|
+
return _jsx(MuiColorInputButton, { ...props, sx: {
|
|
13
|
+
width: 'w-[46px]',
|
|
14
|
+
height: 'w-[90px]',
|
|
15
|
+
borderRadius: 'var(--border-radius-3)',
|
|
16
|
+
border: '1px solid var(--color-grey-300)'
|
|
17
|
+
} });
|
|
18
|
+
};
|
|
19
|
+
return (_jsx(MuiColorInput, { className: "flex flex-grow", format: format, value: data, onChange: onValueChange, isAlphaHidden: isAlphaHidden, Adornment: getAdornmentElement }));
|
|
20
|
+
};
|
|
21
|
+
export const colorPickerControlTester = rankWith(4, optionIs('type', JsonFormsCustomControlKey.COLOR_PICKER));
|
|
22
|
+
export default withJsonFormsControlProps(ColorPickerControl);
|
package/dist/index.d.ts
CHANGED
|
@@ -38,6 +38,7 @@ import DragAndDropBox from './components/fields/DragAndDropBox';
|
|
|
38
38
|
import PersonPlaceholder from './components/assets/placeholders/PersonPlaceholder';
|
|
39
39
|
import PassportPhotoControl, { passportPhotoControlTester } from './components/fields/JSONForms/PassportPhotoControl';
|
|
40
40
|
import CustomArrayControl, { customArrayControlTester } from './components/fields/JSONForms/CustomArrayControl';
|
|
41
|
+
import ColorPickerControl, { colorPickerControlTester } from './components/fields/JSONForms/ColorPickerControl';
|
|
41
42
|
import CredentialIssuanceWizardView from './components/views/CredentialIssuanceWizardView';
|
|
42
43
|
import PaginationControls from './components/views/SSITableView/PaginationControls';
|
|
43
44
|
import PaginationControlsProps from './components/views/SSITableView/PaginationControls';
|
|
@@ -68,4 +69,4 @@ export * from './styles/fonts';
|
|
|
68
69
|
export * from './types';
|
|
69
70
|
export * from './helpers';
|
|
70
71
|
export * from './utils';
|
|
71
|
-
export { SSICredentialCardView, CredentialMiniCardView, CredentialMiniCardViewProps, SSIStatusLabel, SSICheckmarkBadge, SSIExclamationMarkBadge, SSIPlaceholderLogo, SSILogo, SSIAddIcon, SSIFilterIcon, SSIArrowDownIcon, SSITypeLabel, IconButton, PrimaryButton, SecondaryButton, DropDownList, SSITableView, SSITableViewHeader, SSITabView, SSITabViewHeader, SSIProfileIcon, SSIToastContainer, SSICheckbox, SSIActivityIndicator, SSIHoverText, StepMarker, ProgressStepIndicator, PaginationControls, PaginationControlsProps, Row, DocumentIcon, CrossIcon, ImageIcon, MeatBallsIcon, PencilIcon, ViewIcon, CopyIcon, DeleteIcon, FileSelection, ComboBox, DragAndDropBox, PersonPlaceholder, PassportPhotoControl, passportPhotoControlTester, CustomArrayControl, customArrayControlTester, CredentialIssuanceWizardView, CredentialViewItem, JSONDataView, TextInputField, WarningImage, FormView, InformationRequestView, ContactViewItem, CapitolIcon, ChevronIcon, ManIcon, LaptopIcon, StoreIcon, RoleIconView, RoleViewItem, Listbox, ActivityIcon, ContactIcon, BellIcon, CredentialIcon, getFormViewAjv };
|
|
72
|
+
export { SSICredentialCardView, CredentialMiniCardView, CredentialMiniCardViewProps, SSIStatusLabel, SSICheckmarkBadge, SSIExclamationMarkBadge, SSIPlaceholderLogo, SSILogo, SSIAddIcon, SSIFilterIcon, SSIArrowDownIcon, SSITypeLabel, IconButton, PrimaryButton, SecondaryButton, DropDownList, SSITableView, SSITableViewHeader, SSITabView, SSITabViewHeader, SSIProfileIcon, SSIToastContainer, SSICheckbox, SSIActivityIndicator, SSIHoverText, StepMarker, ProgressStepIndicator, PaginationControls, PaginationControlsProps, Row, DocumentIcon, CrossIcon, ImageIcon, MeatBallsIcon, PencilIcon, ViewIcon, CopyIcon, DeleteIcon, FileSelection, ComboBox, DragAndDropBox, PersonPlaceholder, PassportPhotoControl, passportPhotoControlTester, CustomArrayControl, customArrayControlTester, ColorPickerControl, colorPickerControlTester, CredentialIssuanceWizardView, CredentialViewItem, JSONDataView, TextInputField, WarningImage, FormView, InformationRequestView, ContactViewItem, CapitolIcon, ChevronIcon, ManIcon, LaptopIcon, StoreIcon, RoleIconView, RoleViewItem, Listbox, ActivityIcon, ContactIcon, BellIcon, CredentialIcon, getFormViewAjv };
|
package/dist/index.js
CHANGED
|
@@ -38,6 +38,7 @@ import DragAndDropBox from './components/fields/DragAndDropBox';
|
|
|
38
38
|
import PersonPlaceholder from './components/assets/placeholders/PersonPlaceholder';
|
|
39
39
|
import PassportPhotoControl, { passportPhotoControlTester } from './components/fields/JSONForms/PassportPhotoControl';
|
|
40
40
|
import CustomArrayControl, { customArrayControlTester } from './components/fields/JSONForms/CustomArrayControl';
|
|
41
|
+
import ColorPickerControl, { colorPickerControlTester } from './components/fields/JSONForms/ColorPickerControl';
|
|
41
42
|
import CredentialIssuanceWizardView from './components/views/CredentialIssuanceWizardView';
|
|
42
43
|
import PaginationControls from './components/views/SSITableView/PaginationControls';
|
|
43
44
|
import PaginationControlsProps from './components/views/SSITableView/PaginationControls';
|
|
@@ -67,4 +68,4 @@ export * from './styles/fonts';
|
|
|
67
68
|
export * from './types';
|
|
68
69
|
export * from './helpers';
|
|
69
70
|
export * from './utils';
|
|
70
|
-
export { SSICredentialCardView, CredentialMiniCardView, SSIStatusLabel, SSICheckmarkBadge, SSIExclamationMarkBadge, SSIPlaceholderLogo, SSILogo, SSIAddIcon, SSIFilterIcon, SSIArrowDownIcon, SSITypeLabel, IconButton, PrimaryButton, SecondaryButton, DropDownList, SSITableView, SSITableViewHeader, SSITabView, SSITabViewHeader, SSIProfileIcon, SSIToastContainer, SSICheckbox, SSIActivityIndicator, SSIHoverText, StepMarker, ProgressStepIndicator, PaginationControls, PaginationControlsProps, DocumentIcon, CrossIcon, ImageIcon, MeatBallsIcon, PencilIcon, ViewIcon, CopyIcon, DeleteIcon, FileSelection, ComboBox, DragAndDropBox, PersonPlaceholder, PassportPhotoControl, passportPhotoControlTester, CustomArrayControl, customArrayControlTester, CredentialIssuanceWizardView, CredentialViewItem, JSONDataView, TextInputField, WarningImage, FormView, InformationRequestView, ContactViewItem, CapitolIcon, ChevronIcon, ManIcon, LaptopIcon, StoreIcon, RoleIconView, RoleViewItem, Listbox, ActivityIcon, ContactIcon, BellIcon, CredentialIcon, getFormViewAjv };
|
|
71
|
+
export { SSICredentialCardView, CredentialMiniCardView, SSIStatusLabel, SSICheckmarkBadge, SSIExclamationMarkBadge, SSIPlaceholderLogo, SSILogo, SSIAddIcon, SSIFilterIcon, SSIArrowDownIcon, SSITypeLabel, IconButton, PrimaryButton, SecondaryButton, DropDownList, SSITableView, SSITableViewHeader, SSITabView, SSITabViewHeader, SSIProfileIcon, SSIToastContainer, SSICheckbox, SSIActivityIndicator, SSIHoverText, StepMarker, ProgressStepIndicator, PaginationControls, PaginationControlsProps, DocumentIcon, CrossIcon, ImageIcon, MeatBallsIcon, PencilIcon, ViewIcon, CopyIcon, DeleteIcon, FileSelection, ComboBox, DragAndDropBox, PersonPlaceholder, PassportPhotoControl, passportPhotoControlTester, CustomArrayControl, customArrayControlTester, ColorPickerControl, colorPickerControlTester, CredentialIssuanceWizardView, CredentialViewItem, JSONDataView, TextInputField, WarningImage, FormView, InformationRequestView, ContactViewItem, CapitolIcon, ChevronIcon, ManIcon, LaptopIcon, StoreIcon, RoleIconView, RoleViewItem, Listbox, ActivityIcon, ContactIcon, BellIcon, CredentialIcon, getFormViewAjv };
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { materialRenderers } from '@jsonforms/material-renderers';
|
|
2
2
|
import PassportPhotoControl, { passportPhotoControlTester } from '../components/fields/JSONForms/PassportPhotoControl';
|
|
3
3
|
import CustomArrayControl, { customArrayControlTester } from '../components/fields/JSONForms/CustomArrayControl';
|
|
4
|
+
import ColorPickerControl, { colorPickerControlTester } from '../components/fields/JSONForms/ColorPickerControl';
|
|
4
5
|
export const jsonFormsMaterialRenderers = [
|
|
5
6
|
...materialRenderers,
|
|
6
7
|
{ tester: passportPhotoControlTester, renderer: PassportPhotoControl },
|
|
7
8
|
{ tester: customArrayControlTester, renderer: CustomArrayControl },
|
|
9
|
+
{ tester: colorPickerControlTester, renderer: ColorPickerControl },
|
|
8
10
|
];
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export var JsonFormsCustomControlKey;
|
|
2
2
|
(function (JsonFormsCustomControlKey) {
|
|
3
3
|
JsonFormsCustomControlKey["ARRAY"] = "array";
|
|
4
|
-
JsonFormsCustomControlKey["PASSPORT_PHOTO"] = "
|
|
4
|
+
JsonFormsCustomControlKey["PASSPORT_PHOTO"] = "passport-photo";
|
|
5
|
+
JsonFormsCustomControlKey["COLOR_PICKER"] = "color-picker";
|
|
5
6
|
})(JsonFormsCustomControlKey || (JsonFormsCustomControlKey = {}));
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sphereon/ui-components.ssi-react",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.4.1-unstable.
|
|
4
|
+
"version": "0.4.1-unstable.86+728cd63",
|
|
5
5
|
"description": "SSI UI components for React",
|
|
6
6
|
"repository": "git@github.com:Sphereon-Opensource/UI-Components.git",
|
|
7
7
|
"author": "Sphereon <dev@sphereon.com>",
|
|
@@ -36,24 +36,25 @@
|
|
|
36
36
|
"access": "public"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@emotion/react": "^11.
|
|
40
|
-
"@emotion/styled": "^11.
|
|
39
|
+
"@emotion/react": "^11.14.0",
|
|
40
|
+
"@emotion/styled": "^11.14.1",
|
|
41
41
|
"@headlessui/react": "^2.2.4",
|
|
42
|
-
"@jsonforms/core": "^3.
|
|
43
|
-
"@jsonforms/material-renderers": "^3.
|
|
44
|
-
"@jsonforms/react": "^3.
|
|
45
|
-
"@jsonforms/vanilla-renderers": "^3.
|
|
46
|
-
"@mui/icons-material": "^
|
|
47
|
-
"@mui/material": "^
|
|
48
|
-
"@mui/styled-engine-sc": "^
|
|
49
|
-
"@mui/system": "^
|
|
50
|
-
"@mui/x-date-pickers": "^
|
|
42
|
+
"@jsonforms/core": "^3.6.0",
|
|
43
|
+
"@jsonforms/material-renderers": "^3.6.0",
|
|
44
|
+
"@jsonforms/react": "^3.6.0",
|
|
45
|
+
"@jsonforms/vanilla-renderers": "^3.6.0",
|
|
46
|
+
"@mui/icons-material": "^7.3.5",
|
|
47
|
+
"@mui/material": "^7.3.5",
|
|
48
|
+
"@mui/styled-engine-sc": "^7.3.5",
|
|
49
|
+
"@mui/system": "^7.3.5",
|
|
50
|
+
"@mui/x-date-pickers": "^8.18.0",
|
|
51
51
|
"@sphereon/ssi-sdk.data-store": "0.34.1-feature.SSISDK.45.94",
|
|
52
52
|
"@sphereon/ssi-types": "0.34.1-feature.SSISDK.45.94",
|
|
53
|
-
"@sphereon/ui-components.core": "0.4.1-unstable.
|
|
53
|
+
"@sphereon/ui-components.core": "0.4.1-unstable.86+728cd63",
|
|
54
54
|
"@tanstack/react-table": "^8.9.3",
|
|
55
55
|
"ajv": "^8.17.1",
|
|
56
56
|
"ajv-formats": "^3.0.1",
|
|
57
|
+
"mui-color-input": "^7.0.0",
|
|
57
58
|
"react-dom": "npm:react-dom@18.3.1",
|
|
58
59
|
"react-json-tree": "^0.18.0",
|
|
59
60
|
"react-loader-spinner": "5.4.5",
|
|
@@ -71,5 +72,5 @@
|
|
|
71
72
|
"peerDependencies": {
|
|
72
73
|
"react": ">= 18"
|
|
73
74
|
},
|
|
74
|
-
"gitHead": "
|
|
75
|
+
"gitHead": "728cd631c79783d0310869062591a8c773ed984f"
|
|
75
76
|
}
|