@diia-inhouse/test 6.4.0 → 7.2.0
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/LICENCE.md +59 -59
- package/dist/dbUtilsBuilder.js +116 -0
- package/dist/dbUtilsBuilder.js.map +1 -0
- package/dist/documentsGenerator.js.map +1 -1
- package/dist/index.js +3 -5
- package/dist/index.js.map +1 -1
- package/dist/interfaces/documents/foreignPassport.js.map +1 -1
- package/dist/interfaces/documents/index.js.map +1 -1
- package/dist/publicServiceGenerator.js +3 -5
- package/dist/publicServiceGenerator.js.map +1 -1
- package/dist/sessionGenerator.js +7 -24
- package/dist/sessionGenerator.js.map +1 -1
- package/dist/stubs/documents/foreignPassport.js +17 -2
- package/dist/stubs/documents/foreignPassport.js.map +1 -1
- package/dist/stubs/documents/index.js +2 -2
- package/dist/stubs/documents/index.js.map +1 -1
- package/dist/stubs/documents/internalPassport.js +19 -4
- package/dist/stubs/documents/internalPassport.js.map +1 -1
- package/dist/types/dbUtilsBuilder.d.ts +29 -0
- package/dist/types/index.d.ts +1 -1
- package/dist/types/interfaces/documents/foreignPassport.d.ts +2 -1
- package/dist/types/interfaces/documents/index.d.ts +15 -0
- package/dist/types/interfaces/documents/internalPassport.d.ts +2 -1
- package/dist/types/publicServiceGenerator.d.ts +1 -1
- package/dist/types/sessionGenerator.d.ts +4 -5
- package/package.json +35 -39
- package/vitest/extend-expect.ts +25 -0
- package/vitest/interfaces/index.ts +8 -0
- package/vitest/matchers/designSystem/atoms/amountAtm.ts +13 -0
- package/vitest/matchers/designSystem/atoms/articlePicAtm.ts +12 -0
- package/vitest/matchers/designSystem/atoms/badgeCounterAtm.ts +11 -0
- package/vitest/matchers/designSystem/atoms/btnLinkAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnLoadPlainIconAtm.ts +19 -0
- package/vitest/matchers/designSystem/atoms/btnPlainAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnPlainIconAtm.ts +18 -0
- package/vitest/matchers/designSystem/atoms/btnPrimaryAdditionalAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnPrimaryDefaultAtm.ts +17 -0
- package/vitest/matchers/designSystem/atoms/btnPrimaryLargeAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnPrimaryWideAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnSemiLightAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnStrokeAdditionalAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnStrokeDefaultAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/btnWhiteAdditionalIconAtm.ts +20 -0
- package/vitest/matchers/designSystem/atoms/calendarItemAtm.ts +14 -0
- package/vitest/matchers/designSystem/atoms/chipStatusAtm.ts +14 -0
- package/vitest/matchers/designSystem/atoms/dotNavigationAtm.ts +11 -0
- package/vitest/matchers/designSystem/atoms/doubleIconAtm.ts +15 -0
- package/vitest/matchers/designSystem/atoms/greyTitleAtm.ts +12 -0
- package/vitest/matchers/designSystem/atoms/iconAtm.ts +12 -0
- package/vitest/matchers/designSystem/atoms/index.ts +65 -0
- package/vitest/matchers/designSystem/atoms/inputNumberLargeAtm.ts +15 -0
- package/vitest/matchers/designSystem/atoms/largeIconAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/playerBtnAtm.ts +12 -0
- package/vitest/matchers/designSystem/atoms/sectionTitleAtm.ts +11 -0
- package/vitest/matchers/designSystem/atoms/shared/buttonAction.ts +15 -0
- package/vitest/matchers/designSystem/atoms/shared/iconAction.ts +13 -0
- package/vitest/matchers/designSystem/atoms/simpleIconAtm.ts +12 -0
- package/vitest/matchers/designSystem/atoms/smallIconAtm.ts +16 -0
- package/vitest/matchers/designSystem/atoms/textParameterAtm.ts +19 -0
- package/vitest/matchers/designSystem/atoms/tickerAtm.ts +20 -0
- package/vitest/matchers/designSystem/atoms/userPictureAtm.ts +14 -0
- package/vitest/matchers/designSystem/atoms/validationAtm.ts +13 -0
- package/vitest/matchers/designSystem/enums/button.ts +5 -0
- package/vitest/matchers/designSystem/enums/icon.ts +5 -0
- package/vitest/matchers/designSystem/index.ts +7 -0
- package/vitest/matchers/designSystem/molecules/articleVideoMlc.ts +13 -0
- package/vitest/matchers/designSystem/molecules/attentionIconMessageMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/attentionMessageMlc.ts +18 -0
- package/vitest/matchers/designSystem/molecules/barCodeMlc.ts +12 -0
- package/vitest/matchers/designSystem/molecules/blackCardMlc.ts +20 -0
- package/vitest/matchers/designSystem/molecules/btnIconPlainGroupMlc.ts +17 -0
- package/vitest/matchers/designSystem/molecules/btnIconRoundedMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/btnLoadIconPlainGroupMlc.ts +17 -0
- package/vitest/matchers/designSystem/molecules/btnToggleMlc.ts +26 -0
- package/vitest/matchers/designSystem/molecules/cardMlc.ts +33 -0
- package/vitest/matchers/designSystem/molecules/cardMlcTicker.ts +12 -0
- package/vitest/matchers/designSystem/molecules/checkIconMlc.ts +13 -0
- package/vitest/matchers/designSystem/molecules/checkboxRoundMlc.ts +11 -0
- package/vitest/matchers/designSystem/molecules/checkboxSquareMlc.ts +22 -0
- package/vitest/matchers/designSystem/molecules/chipMlc.ts +22 -0
- package/vitest/matchers/designSystem/molecules/chipTimeMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/currentTimeMlc.ts +20 -0
- package/vitest/matchers/designSystem/molecules/dashboardCardMlc.ts +23 -0
- package/vitest/matchers/designSystem/molecules/docNumberCopyMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/docNumberCopyWhiteMlc.ts +14 -0
- package/vitest/matchers/designSystem/molecules/docTableItemHorizontalLongerMlc.ts +18 -0
- package/vitest/matchers/designSystem/molecules/docTableItemHorizontalMlc.ts +19 -0
- package/vitest/matchers/designSystem/molecules/halvedCardMlc.ts +21 -0
- package/vitest/matchers/designSystem/molecules/headingWithSubtitleWhiteMlc.ts +12 -0
- package/vitest/matchers/designSystem/molecules/headingWithSubtitlesMlc.ts +13 -0
- package/vitest/matchers/designSystem/molecules/iconCardMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/imageCardMlc.ts +21 -0
- package/vitest/matchers/designSystem/molecules/index.ts +121 -0
- package/vitest/matchers/designSystem/molecules/inputDateMlc.ts +19 -0
- package/vitest/matchers/designSystem/molecules/inputNumberFractionalMlc.ts +21 -0
- package/vitest/matchers/designSystem/molecules/inputNumberLargeMlc.ts +17 -0
- package/vitest/matchers/designSystem/molecules/inputNumberMlc.ts +20 -0
- package/vitest/matchers/designSystem/molecules/inputTextMlc.ts +21 -0
- package/vitest/matchers/designSystem/molecules/inputTextMultilineMlc.ts +21 -0
- package/vitest/matchers/designSystem/molecules/listItemMlc.ts +32 -0
- package/vitest/matchers/designSystem/molecules/listWidgetItemMlc.ts +24 -0
- package/vitest/matchers/designSystem/molecules/navigationPanelMlc.ts +49 -0
- package/vitest/matchers/designSystem/molecules/qrCodeMlc.ts +12 -0
- package/vitest/matchers/designSystem/molecules/radioBtnMlc.ts +28 -0
- package/vitest/matchers/designSystem/molecules/searchInputMlc.ts +19 -0
- package/vitest/matchers/designSystem/molecules/smallEmojiPanelMlc.ts +13 -0
- package/vitest/matchers/designSystem/molecules/smallEmojiPanelPlaneMlc.ts +13 -0
- package/vitest/matchers/designSystem/molecules/smallNotificationMlc.ts +20 -0
- package/vitest/matchers/designSystem/molecules/stackMlc.ts +13 -0
- package/vitest/matchers/designSystem/molecules/statusMessageMlc.ts +16 -0
- package/vitest/matchers/designSystem/molecules/stubMessageMlc.ts +18 -0
- package/vitest/matchers/designSystem/molecules/subtitleLabelMlc.ts +14 -0
- package/vitest/matchers/designSystem/molecules/tableItemHorizontalLargeMlc.ts +22 -0
- package/vitest/matchers/designSystem/molecules/tableItemHorizontalMlc.ts +19 -0
- package/vitest/matchers/designSystem/molecules/tableItemMlc.ts +23 -0
- package/vitest/matchers/designSystem/molecules/tableItemPrimaryMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/tableItemVerticalMlc.ts +22 -0
- package/vitest/matchers/designSystem/molecules/tableMainHeadingMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/tableSecondaryHeadingMlc.ts +14 -0
- package/vitest/matchers/designSystem/molecules/textLabelContainerMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/textLabelMlc.ts +23 -0
- package/vitest/matchers/designSystem/molecules/timerMlc.ts +36 -0
- package/vitest/matchers/designSystem/molecules/titleGroupMlc.ts +27 -0
- package/vitest/matchers/designSystem/molecules/titleLabelMlc.ts +12 -0
- package/vitest/matchers/designSystem/molecules/userCardMlc.ts +15 -0
- package/vitest/matchers/designSystem/molecules/verticalCardMlc.ts +22 -0
- package/vitest/matchers/designSystem/molecules/whiteCardMlc.ts +19 -0
- package/vitest/matchers/designSystem/organisms/articlePicCarouselOrg.ts +20 -0
- package/vitest/matchers/designSystem/organisms/bottomGroupOrg.ts +25 -0
- package/vitest/matchers/designSystem/organisms/btnIconRoundedGroupOrg.ts +16 -0
- package/vitest/matchers/designSystem/organisms/calendarItemOrg.ts +16 -0
- package/vitest/matchers/designSystem/organisms/checkboxBtnOrg.ts +21 -0
- package/vitest/matchers/designSystem/organisms/checkboxRoundGroupOrg.ts +22 -0
- package/vitest/matchers/designSystem/organisms/chipGroupOrg.ts +21 -0
- package/vitest/matchers/designSystem/organisms/chipTabsOrg.ts +22 -0
- package/vitest/matchers/designSystem/organisms/dashboardCardTileOrg.ts +17 -0
- package/vitest/matchers/designSystem/organisms/docButtonHeadingOrg.ts +20 -0
- package/vitest/matchers/designSystem/organisms/docHeadingOrg.ts +19 -0
- package/vitest/matchers/designSystem/organisms/editAutomaticallyDeterminedValueOrg.ts +18 -0
- package/vitest/matchers/designSystem/organisms/fileUploadGroupOrg.ts +17 -0
- package/vitest/matchers/designSystem/organisms/fullScreenVideoOrg.ts +17 -0
- package/vitest/matchers/designSystem/organisms/groupFilesAddOrg.ts +19 -0
- package/vitest/matchers/designSystem/organisms/halvedCardCarouselOrg.ts +20 -0
- package/vitest/matchers/designSystem/organisms/index.ts +83 -0
- package/vitest/matchers/designSystem/organisms/inputDateTimeOrg.ts +16 -0
- package/vitest/matchers/designSystem/organisms/inputNumLargeTimeOrg.ts +19 -0
- package/vitest/matchers/designSystem/organisms/listItemGroupOrg.ts +11 -0
- package/vitest/matchers/designSystem/organisms/mediaTitleOrg.ts +14 -0
- package/vitest/matchers/designSystem/organisms/mediaUploadGroupOrg.ts +16 -0
- package/vitest/matchers/designSystem/organisms/paginationListOrg.ts +19 -0
- package/vitest/matchers/designSystem/organisms/paginationListWhiteOrg.ts +20 -0
- package/vitest/matchers/designSystem/organisms/paymentInfoOrg.ts +23 -0
- package/vitest/matchers/designSystem/organisms/questionFormsOrg.ts +28 -0
- package/vitest/matchers/designSystem/organisms/radioBtnAdditionalInputOrg.ts +14 -0
- package/vitest/matchers/designSystem/organisms/radioBtnGroupOrg.ts +28 -0
- package/vitest/matchers/designSystem/organisms/radioBtnWithAltOrg.ts +17 -0
- package/vitest/matchers/designSystem/organisms/searchBarOrg.ts +15 -0
- package/vitest/matchers/designSystem/organisms/selectorListWidgetOrg.ts +16 -0
- package/vitest/matchers/designSystem/organisms/selectorOrg.ts +24 -0
- package/vitest/matchers/designSystem/organisms/sharingCodesOrg.ts +24 -0
- package/vitest/matchers/designSystem/organisms/smallNotificationCarouselOrg.ts +20 -0
- package/vitest/matchers/designSystem/organisms/tableBlockAccordionOrg.ts +15 -0
- package/vitest/matchers/designSystem/organisms/tableBlockOrg.ts +17 -0
- package/vitest/matchers/designSystem/organisms/tableBlockPlaneOrg.ts +17 -0
- package/vitest/matchers/designSystem/organisms/tableBlockTwoColumnsOrg.ts +15 -0
- package/vitest/matchers/designSystem/organisms/tableBlockTwoColumnsPlaneOrg.ts +16 -0
- package/vitest/matchers/designSystem/organisms/toggleButtonGroupOrg.ts +18 -0
- package/vitest/matchers/designSystem/organisms/topGroupOrg.ts +17 -0
- package/vitest/matchers/designSystem/organisms/verificationCodesOrg.ts +31 -0
- package/vitest/matchers/designSystem/organisms/verticalCardCarouselOrg.ts +16 -0
- package/vitest/matchers/designSystem/utils.ts +14 -0
- package/vitest/matchers/index.ts +21 -0
- package/vitest/matchers/toBe.ts +38 -0
- package/vitest/matchers/toBeAttentionMessage/index.ts +19 -0
- package/vitest/matchers/toBeAttentionMessage/interfaces.ts +8 -0
- package/vitest/matchers/toBeAttentionMessageParameter.ts +20 -0
- package/vitest/matchers/toBeContextMenu/index.ts +25 -0
- package/vitest/matchers/toBeContextMenu/interfaces.ts +9 -0
- package/vitest/matchers/toBeDesignSystemElement/index.ts +8 -0
- package/vitest/matchers/toBeMainButton/index.ts +19 -0
- package/vitest/matchers/toBeMainButton/interfaces.ts +5 -0
- package/vitest/matchers/toBeNavigationPanel/index.ts +17 -0
- package/vitest/matchers/toBeNavigationPanel/interfaces.ts +6 -0
- package/vitest/matchers/toBeTextWithParameters/index.ts +17 -0
- package/vitest/matchers/toBeTextWithParameters/interfaces.ts +6 -0
- package/vitest/matchers/toBeValueWithLabel/index.ts +18 -0
- package/vitest/matchers/toBeValueWithLabel/interfaces.ts +4 -0
- package/vitest/matchers/toContainObjects.ts +17 -0
- package/vitest/matchers/toEqual.ts +26 -0
- package/vitest/matchers/toInterceptorsBeDone.ts +18 -0
- package/vitest/tsconfig.json +9 -0
- package/vitest/utils.ts +144 -0
- package/dist/interfaces/documents/eResidency.js +0 -15
- package/dist/interfaces/documents/eResidency.js.map +0 -1
- package/dist/interfaces/documents/residencePermit.js +0 -9
- package/dist/interfaces/documents/residencePermit.js.map +0 -1
- package/dist/mock.js +0 -29
- package/dist/mock.js.map +0 -1
- package/dist/mongooseMock.js +0 -43
- package/dist/mongooseMock.js.map +0 -1
- package/dist/stubs/documents/eResidency.js +0 -48
- package/dist/stubs/documents/eResidency.js.map +0 -1
- package/dist/stubs/documents/residencePermit.js +0 -48
- package/dist/stubs/documents/residencePermit.js.map +0 -1
- package/dist/types/interfaces/documents/eResidency.d.ts +0 -77
- package/dist/types/interfaces/documents/residencePermit.d.ts +0 -50
- package/dist/types/mock.d.ts +0 -5
- package/dist/types/mongooseMock.d.ts +0 -33
- package/dist/types/stubs/documents/eResidency.d.ts +0 -3
- package/dist/types/stubs/documents/residencePermit.d.ts +0 -3
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { DocNumberCopyWhiteMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconAtmSchema } from '../atoms/iconAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<DocNumberCopyWhiteMlc> = object({
|
|
9
|
+
value: string(),
|
|
10
|
+
label: optional(string()),
|
|
11
|
+
icon: optional(iconAtmSchema),
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
export const docNumberCopyWhiteMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { DocTableItemHorizontalLongerMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconAtmSchema } from '../atoms/iconAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<DocTableItemHorizontalLongerMlc> = object({
|
|
9
|
+
label: string(),
|
|
10
|
+
supportingValue: optional(string()),
|
|
11
|
+
secondaryLabel: optional(string()),
|
|
12
|
+
value: string(),
|
|
13
|
+
secondaryValue: optional(string()),
|
|
14
|
+
valueImage: optional(string()),
|
|
15
|
+
icon: optional(iconAtmSchema),
|
|
16
|
+
})
|
|
17
|
+
|
|
18
|
+
export const docTableItemHorizontalLongerMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { DocTableItemHorizontalMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconAtmSchema } from '../atoms/iconAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<DocTableItemHorizontalMlc> = object({
|
|
9
|
+
label: string(),
|
|
10
|
+
supportingValue: optional(string()),
|
|
11
|
+
secondaryLabel: optional(string()),
|
|
12
|
+
value: string(),
|
|
13
|
+
secondaryValue: optional(string()),
|
|
14
|
+
valueImage: optional(string()),
|
|
15
|
+
icon: optional(iconAtmSchema),
|
|
16
|
+
componentId: optional(string()),
|
|
17
|
+
})
|
|
18
|
+
|
|
19
|
+
export const docTableItemHorizontalMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { HalvedCardAction, HalvedCardMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const halvedCardActionSchema: Describe<HalvedCardAction> = object({
|
|
8
|
+
type: string(),
|
|
9
|
+
resource: optional(string()),
|
|
10
|
+
subtype: optional(string()),
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
const schema: Describe<HalvedCardMlc> = object({
|
|
14
|
+
image: string(),
|
|
15
|
+
title: string(),
|
|
16
|
+
label: string(),
|
|
17
|
+
id: optional(string()),
|
|
18
|
+
action: optional(halvedCardActionSchema),
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
export const halvedCardMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Describe, array, object, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { HeadingWithSubtitleWhiteMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const schema: Describe<HeadingWithSubtitleWhiteMlc> = object({
|
|
8
|
+
value: string(),
|
|
9
|
+
subtitles: array(string()),
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
export const headingWithSubtitleWhiteMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Describe, array, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { HeadingWithSubtitlesMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const schema: Describe<HeadingWithSubtitlesMlc> = object({
|
|
8
|
+
value: string(),
|
|
9
|
+
subtitles: array(string()),
|
|
10
|
+
componentId: optional(string()),
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
export const headingWithSubtitlesMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Describe, object, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { IconCardMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { buttonActionSchema } from '../atoms/shared/buttonAction'
|
|
6
|
+
import { iconSchema } from '../enums/icon'
|
|
7
|
+
import { schemaBuilder } from '../utils'
|
|
8
|
+
|
|
9
|
+
const schema: Describe<IconCardMlc> = object({
|
|
10
|
+
label: string(),
|
|
11
|
+
iconLeft: iconSchema,
|
|
12
|
+
action: buttonActionSchema(),
|
|
13
|
+
})
|
|
14
|
+
|
|
15
|
+
export const iconCardMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { ImageCardAction, ImageCardMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconSchema } from '../enums/icon'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const imageCardActionSchema: Describe<ImageCardAction> = object({
|
|
9
|
+
type: string(),
|
|
10
|
+
resource: optional(string()),
|
|
11
|
+
subtype: optional(string()),
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
const schema: Describe<ImageCardMlc> = object({
|
|
15
|
+
image: string(),
|
|
16
|
+
label: string(),
|
|
17
|
+
iconRight: iconSchema,
|
|
18
|
+
action: optional(imageCardActionSchema),
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
export const imageCardMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
export * from './articleVideoMlc'
|
|
2
|
+
|
|
3
|
+
export * from './attentionMessageMlc'
|
|
4
|
+
|
|
5
|
+
export * from './barCodeMlc'
|
|
6
|
+
|
|
7
|
+
export * from './blackCardMlc'
|
|
8
|
+
|
|
9
|
+
export * from './btnIconPlainGroupMlc'
|
|
10
|
+
|
|
11
|
+
export * from './btnIconRoundedMlc'
|
|
12
|
+
|
|
13
|
+
export * from './btnLoadIconPlainGroupMlc'
|
|
14
|
+
|
|
15
|
+
export * from './btnToggleMlc'
|
|
16
|
+
|
|
17
|
+
export * from './cardMlc'
|
|
18
|
+
|
|
19
|
+
export * from './cardMlcTicker'
|
|
20
|
+
|
|
21
|
+
export * from './checkIconMlc'
|
|
22
|
+
|
|
23
|
+
export * from './checkboxRoundMlc'
|
|
24
|
+
|
|
25
|
+
export * from './checkboxSquareMlc'
|
|
26
|
+
|
|
27
|
+
export * from './chipMlc'
|
|
28
|
+
|
|
29
|
+
export * from './chipTimeMlc'
|
|
30
|
+
|
|
31
|
+
export * from './currentTimeMlc'
|
|
32
|
+
|
|
33
|
+
export * from './dashboardCardMlc'
|
|
34
|
+
|
|
35
|
+
export * from './docNumberCopyMlc'
|
|
36
|
+
|
|
37
|
+
export * from './docNumberCopyWhiteMlc'
|
|
38
|
+
|
|
39
|
+
export * from './docTableItemHorizontalLongerMlc'
|
|
40
|
+
|
|
41
|
+
export * from './docTableItemHorizontalMlc'
|
|
42
|
+
|
|
43
|
+
export * from './halvedCardMlc'
|
|
44
|
+
|
|
45
|
+
export * from './headingWithSubtitleWhiteMlc'
|
|
46
|
+
|
|
47
|
+
export * from './headingWithSubtitlesMlc'
|
|
48
|
+
|
|
49
|
+
export * from './iconCardMlc'
|
|
50
|
+
|
|
51
|
+
export * from './imageCardMlc'
|
|
52
|
+
|
|
53
|
+
export * from './inputDateMlc'
|
|
54
|
+
|
|
55
|
+
export * from './inputNumberFractionalMlc'
|
|
56
|
+
|
|
57
|
+
export * from './inputNumberLargeMlc'
|
|
58
|
+
|
|
59
|
+
export * from './inputNumberMlc'
|
|
60
|
+
|
|
61
|
+
export * from './inputTextMlc'
|
|
62
|
+
|
|
63
|
+
export * from './inputTextMultilineMlc'
|
|
64
|
+
|
|
65
|
+
export * from './listItemMlc'
|
|
66
|
+
|
|
67
|
+
export * from './listWidgetItemMlc'
|
|
68
|
+
|
|
69
|
+
export * from './navigationPanelMlc'
|
|
70
|
+
|
|
71
|
+
export * from './qrCodeMlc'
|
|
72
|
+
|
|
73
|
+
export * from './radioBtnMlc'
|
|
74
|
+
|
|
75
|
+
export * from './searchInputMlc'
|
|
76
|
+
|
|
77
|
+
export * from './smallEmojiPanelMlc'
|
|
78
|
+
|
|
79
|
+
export * from './smallEmojiPanelPlaneMlc'
|
|
80
|
+
|
|
81
|
+
export * from './smallNotificationMlc'
|
|
82
|
+
|
|
83
|
+
export * from './stackMlc'
|
|
84
|
+
|
|
85
|
+
export * from './statusMessageMlc'
|
|
86
|
+
|
|
87
|
+
export * from './stubMessageMlc'
|
|
88
|
+
|
|
89
|
+
export * from './subtitleLabelMlc'
|
|
90
|
+
|
|
91
|
+
export * from './tableItemHorizontalLargeMlc'
|
|
92
|
+
|
|
93
|
+
export * from './tableItemHorizontalMlc'
|
|
94
|
+
|
|
95
|
+
export * from './tableItemMlc'
|
|
96
|
+
|
|
97
|
+
export * from './tableItemPrimaryMlc'
|
|
98
|
+
|
|
99
|
+
export * from './tableItemVerticalMlc'
|
|
100
|
+
|
|
101
|
+
export * from './tableMainHeadingMlc'
|
|
102
|
+
|
|
103
|
+
export * from './tableSecondaryHeadingMlc'
|
|
104
|
+
|
|
105
|
+
export * from './textLabelContainerMlc'
|
|
106
|
+
|
|
107
|
+
export * from './textLabelMlc'
|
|
108
|
+
|
|
109
|
+
export * from './timerMlc'
|
|
110
|
+
|
|
111
|
+
export * from './titleGroupMlc'
|
|
112
|
+
|
|
113
|
+
export * from './titleLabelMlc'
|
|
114
|
+
|
|
115
|
+
export * from './userCardMlc'
|
|
116
|
+
|
|
117
|
+
export * from './verticalCardMlc'
|
|
118
|
+
|
|
119
|
+
export * from './whiteCardMlc'
|
|
120
|
+
|
|
121
|
+
export * from './attentionIconMessageMlc'
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Describe, boolean, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { InputDateMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const schema: Describe<InputDateMlc> = object({
|
|
8
|
+
id: string(),
|
|
9
|
+
blocker: optional(boolean()),
|
|
10
|
+
label: string(),
|
|
11
|
+
value: optional(string()),
|
|
12
|
+
hint: optional(string()),
|
|
13
|
+
dateFormat: optional(string()),
|
|
14
|
+
componentId: string(),
|
|
15
|
+
mandatory: optional(boolean()),
|
|
16
|
+
placeholder: optional(string()),
|
|
17
|
+
})
|
|
18
|
+
|
|
19
|
+
export const inputDateMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Describe, boolean, number, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { InputNumberFractionalMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const schema: Describe<InputNumberFractionalMlc> = object({
|
|
8
|
+
componentId: optional(string()),
|
|
9
|
+
inputCode: optional(string()),
|
|
10
|
+
label: string(),
|
|
11
|
+
placeholder: optional(string()),
|
|
12
|
+
hint: optional(string()),
|
|
13
|
+
value: optional(string()),
|
|
14
|
+
maxValue: optional(number()),
|
|
15
|
+
minValue: optional(number()),
|
|
16
|
+
decimalCount: optional(number()),
|
|
17
|
+
mandatory: optional(boolean()),
|
|
18
|
+
errorMessage: optional(string()),
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
export const inputNumberFractionalMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Describe, array, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { InputNumberLargeMlc, InputNumberLargeMlcItem } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { inputNumberLargeAtmSchema } from '../atoms/inputNumberLargeAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const inputNumberLargeMlcItemSchema: Describe<InputNumberLargeMlcItem> = object({
|
|
9
|
+
inputNumberLargeAtm: optional(inputNumberLargeAtmSchema()),
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
const schema: Describe<InputNumberLargeMlc> = object({
|
|
13
|
+
componentId: optional(string()),
|
|
14
|
+
items: array(inputNumberLargeMlcItemSchema),
|
|
15
|
+
})
|
|
16
|
+
|
|
17
|
+
export const inputNumberLargeMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Describe, boolean, number, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { InputNumberMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const schema: Describe<InputNumberMlc> = object({
|
|
8
|
+
componentId: optional(string()),
|
|
9
|
+
inputCode: optional(string()),
|
|
10
|
+
label: string(),
|
|
11
|
+
placeholder: optional(string()),
|
|
12
|
+
hint: optional(string()),
|
|
13
|
+
value: optional(string()),
|
|
14
|
+
maxValue: optional(number()),
|
|
15
|
+
minValue: optional(number()),
|
|
16
|
+
mandatory: optional(boolean()),
|
|
17
|
+
errorMessage: optional(string()),
|
|
18
|
+
})
|
|
19
|
+
|
|
20
|
+
export const inputNumberMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Describe, array, boolean, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { InputTextMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { validationAtmSchema } from '../atoms/validationAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<InputTextMlc> = object({
|
|
9
|
+
id: optional(string()),
|
|
10
|
+
blocker: optional(boolean()),
|
|
11
|
+
label: string(),
|
|
12
|
+
placeholder: optional(string()),
|
|
13
|
+
hint: optional(string()),
|
|
14
|
+
value: optional(string()),
|
|
15
|
+
mandatory: optional(boolean()),
|
|
16
|
+
validation: array(validationAtmSchema()),
|
|
17
|
+
inputCode: optional(string()),
|
|
18
|
+
componentId: optional(string()),
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
export const inputTextMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Describe, array, boolean, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { InputTextMultilineMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { validationAtmSchema } from '../atoms/validationAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<InputTextMultilineMlc> = object({
|
|
9
|
+
id: optional(string()),
|
|
10
|
+
blocker: optional(boolean()),
|
|
11
|
+
label: string(),
|
|
12
|
+
placeholder: optional(string()),
|
|
13
|
+
hint: optional(string()),
|
|
14
|
+
value: optional(string()),
|
|
15
|
+
mandatory: optional(boolean()),
|
|
16
|
+
validation: array(validationAtmSchema()),
|
|
17
|
+
inputCode: optional(string()),
|
|
18
|
+
componentId: optional(string()),
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
export const inputTextMultilineMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { ListItemMlc, ListItemMlcIcon } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { amountAtmSchema } from '../atoms/amountAtm'
|
|
6
|
+
import { chipStatusAtmSchema } from '../atoms/chipStatusAtm'
|
|
7
|
+
import { buttonActionSchema } from '../atoms/shared/buttonAction'
|
|
8
|
+
import { buttonStateSchema } from '../enums/button'
|
|
9
|
+
import { iconSchema } from '../enums/icon'
|
|
10
|
+
import { schemaBuilder } from '../utils'
|
|
11
|
+
|
|
12
|
+
const listItemMlcIconSchema: Describe<ListItemMlcIcon> = object({
|
|
13
|
+
code: iconSchema,
|
|
14
|
+
})
|
|
15
|
+
|
|
16
|
+
const schema: Describe<ListItemMlc> = object({
|
|
17
|
+
id: optional(string()),
|
|
18
|
+
label: string(),
|
|
19
|
+
description: optional(string()),
|
|
20
|
+
logoLeft: optional(string()),
|
|
21
|
+
action: optional(buttonActionSchema()),
|
|
22
|
+
state: optional(buttonStateSchema),
|
|
23
|
+
componentId: optional(string()),
|
|
24
|
+
dataJson: optional(string()),
|
|
25
|
+
amountAtm: optional(amountAtmSchema()),
|
|
26
|
+
chipStatusAtm: optional(chipStatusAtmSchema()),
|
|
27
|
+
iconLeft: optional(listItemMlcIconSchema),
|
|
28
|
+
iconRight: optional(listItemMlcIconSchema),
|
|
29
|
+
leftLogoLink: optional(string()),
|
|
30
|
+
})
|
|
31
|
+
|
|
32
|
+
export const listItemMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { ListWidgetItemMlc, ListWidgetItemMlcIcon } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { buttonStateSchema } from '../enums/button'
|
|
6
|
+
import { iconSchema } from '../enums/icon'
|
|
7
|
+
import { schemaBuilder } from '../utils'
|
|
8
|
+
|
|
9
|
+
const listWidgetItemMlcIconSchema: Describe<ListWidgetItemMlcIcon> = object({
|
|
10
|
+
code: iconSchema,
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
const schema: Describe<ListWidgetItemMlc> = object({
|
|
14
|
+
componentId: string(),
|
|
15
|
+
label: string(),
|
|
16
|
+
description: optional(string()),
|
|
17
|
+
iconLeft: optional(listWidgetItemMlcIconSchema),
|
|
18
|
+
iconRight: optional(listWidgetItemMlcIconSchema),
|
|
19
|
+
state: optional(buttonStateSchema),
|
|
20
|
+
dataJson: optional(string()),
|
|
21
|
+
id: string(),
|
|
22
|
+
})
|
|
23
|
+
|
|
24
|
+
export const listWidgetItemMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { Describe, array, enums, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { AppVersions, NavigationPanelMlc, PublicServiceContextMenu, PublicServiceContextMenuType } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconAtmSchema } from '../atoms/iconAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const appVersionsSchema: Describe<AppVersions> = object({
|
|
9
|
+
minVersion: optional(
|
|
10
|
+
object({
|
|
11
|
+
iOS: optional(string()),
|
|
12
|
+
Android: optional(string()),
|
|
13
|
+
Huawei: optional(string()),
|
|
14
|
+
Browser: optional(string()),
|
|
15
|
+
}),
|
|
16
|
+
),
|
|
17
|
+
maxVersion: optional(
|
|
18
|
+
object({
|
|
19
|
+
iOS: optional(string()),
|
|
20
|
+
Android: optional(string()),
|
|
21
|
+
Huawei: optional(string()),
|
|
22
|
+
Browser: optional(string()),
|
|
23
|
+
}),
|
|
24
|
+
),
|
|
25
|
+
versions: optional(
|
|
26
|
+
object({
|
|
27
|
+
iOS: optional(array(string())),
|
|
28
|
+
Android: optional(array(string())),
|
|
29
|
+
Huawei: optional(array(string())),
|
|
30
|
+
Browser: optional(array(string())),
|
|
31
|
+
}),
|
|
32
|
+
),
|
|
33
|
+
})
|
|
34
|
+
|
|
35
|
+
const publicServiceContextMenuSchema: Describe<PublicServiceContextMenu> = object({
|
|
36
|
+
name: string(),
|
|
37
|
+
code: optional(string()),
|
|
38
|
+
appVersions: optional(appVersionsSchema),
|
|
39
|
+
type: enums(Object.values(PublicServiceContextMenuType)),
|
|
40
|
+
})
|
|
41
|
+
|
|
42
|
+
const schema: Describe<NavigationPanelMlc> = object({
|
|
43
|
+
componentId: optional(string()),
|
|
44
|
+
ellipseMenu: array(publicServiceContextMenuSchema),
|
|
45
|
+
label: optional(string()),
|
|
46
|
+
iconAtm: optional(iconAtmSchema),
|
|
47
|
+
})
|
|
48
|
+
|
|
49
|
+
export const navigationPanelMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { QrCodeMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const schema: Describe<QrCodeMlc> = object({
|
|
8
|
+
qrLink: string(),
|
|
9
|
+
componentId: optional(string()),
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
export const qrCodeMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Describe, boolean, enums, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { CheckableAtmType, RadioBtnMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { amountAtmSchema } from '../atoms/amountAtm'
|
|
6
|
+
import { chipStatusAtmSchema } from '../atoms/chipStatusAtm'
|
|
7
|
+
import { buttonActionSchema } from '../atoms/shared/buttonAction'
|
|
8
|
+
import { schemaBuilder } from '../utils'
|
|
9
|
+
|
|
10
|
+
const schema: Describe<RadioBtnMlc> = object({
|
|
11
|
+
id: optional(string()),
|
|
12
|
+
label: string(),
|
|
13
|
+
description: optional(string()),
|
|
14
|
+
action: optional(buttonActionSchema()),
|
|
15
|
+
componentId: optional(string()),
|
|
16
|
+
dataJson: optional(string()),
|
|
17
|
+
amountAtm: optional(amountAtmSchema()),
|
|
18
|
+
chipStatusAtm: optional(chipStatusAtmSchema()),
|
|
19
|
+
logoLeft: optional(string()),
|
|
20
|
+
logoRight: optional(string()),
|
|
21
|
+
isEnabled: optional(boolean()),
|
|
22
|
+
isSelected: optional(boolean()),
|
|
23
|
+
status: optional(string()),
|
|
24
|
+
largeLogoRight: optional(string()),
|
|
25
|
+
state: optional(enums(Object.values(CheckableAtmType))),
|
|
26
|
+
})
|
|
27
|
+
|
|
28
|
+
export const radioBtnMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { SearchInputMlc, SearchInputMlcIcon } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconSchema } from '../enums/icon'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const searchInputMlcIconSchema: Describe<SearchInputMlcIcon> = object({
|
|
9
|
+
code: iconSchema,
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
const schema: Describe<SearchInputMlc> = object({
|
|
13
|
+
componentId: string(),
|
|
14
|
+
label: string(),
|
|
15
|
+
iconLeft: optional(searchInputMlcIconSchema),
|
|
16
|
+
iconRight: optional(searchInputMlcIconSchema),
|
|
17
|
+
})
|
|
18
|
+
|
|
19
|
+
export const searchInputMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { SmallEmojiPanelMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconAtmSchema } from '../atoms/iconAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<SmallEmojiPanelMlc> = object({
|
|
9
|
+
label: string(),
|
|
10
|
+
icon: optional(iconAtmSchema),
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
export const smallEmojiPanelMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { SmallEmojiPanelPlaneMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { iconAtmSchema } from '../atoms/iconAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<SmallEmojiPanelPlaneMlc> = object({
|
|
9
|
+
label: string(),
|
|
10
|
+
icon: optional(iconAtmSchema),
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
export const smallEmojiPanelPlaneMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Describe, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { SmallNoitificationAction, SmallNotificationMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { schemaBuilder } from '../utils'
|
|
6
|
+
|
|
7
|
+
const smallNotificationMlcActionSchema: Describe<SmallNoitificationAction> = object({
|
|
8
|
+
type: string(),
|
|
9
|
+
subtype: optional(string()),
|
|
10
|
+
resource: optional(string()),
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
const schema: Describe<SmallNotificationMlc> = object({
|
|
14
|
+
id: string(),
|
|
15
|
+
label: string(),
|
|
16
|
+
text: string(),
|
|
17
|
+
action: optional(smallNotificationMlcActionSchema),
|
|
18
|
+
})
|
|
19
|
+
|
|
20
|
+
export const smallNotificationMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Describe, number, object } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { StackMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { smallIconAtmSchema } from '../atoms/smallIconAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<StackMlc> = object({
|
|
9
|
+
amount: number(),
|
|
10
|
+
smallIconAtm: smallIconAtmSchema(),
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
export const stackMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Describe, array, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { StatusMessageMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { textParameterAtmSchema } from '../atoms/textParameterAtm'
|
|
6
|
+
import { schemaBuilder } from '../utils'
|
|
7
|
+
|
|
8
|
+
const schema: Describe<StatusMessageMlc> = object({
|
|
9
|
+
componentId: optional(string()),
|
|
10
|
+
title: string(),
|
|
11
|
+
icon: string(),
|
|
12
|
+
text: string(),
|
|
13
|
+
parameters: array(textParameterAtmSchema()),
|
|
14
|
+
})
|
|
15
|
+
|
|
16
|
+
export const statusMessageMlcSchema = schemaBuilder(schema)
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Describe, array, object, optional, string } from 'superstruct'
|
|
2
|
+
|
|
3
|
+
import { StubMessageMlc } from '@diia-inhouse/types'
|
|
4
|
+
|
|
5
|
+
import { btnStrokeAdditionalAtmSchema } from '../atoms/btnStrokeAdditionalAtm'
|
|
6
|
+
import { textParameterAtmSchema } from '../atoms/textParameterAtm'
|
|
7
|
+
import { schemaBuilder } from '../utils'
|
|
8
|
+
|
|
9
|
+
const schema: Describe<StubMessageMlc> = object({
|
|
10
|
+
icon: string(),
|
|
11
|
+
title: string(),
|
|
12
|
+
description: optional(string()),
|
|
13
|
+
parameters: array(textParameterAtmSchema()),
|
|
14
|
+
btnStrokeAdditionalAtm: optional(btnStrokeAdditionalAtmSchema()),
|
|
15
|
+
componentId: optional(string()),
|
|
16
|
+
})
|
|
17
|
+
|
|
18
|
+
export const stubMessageMlcSchema = schemaBuilder(schema)
|