@sphereon/ssi-sdk.data-store 0.11.1-unstable.64 → 0.12.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/README.md +5 -0
- package/dist/contact/AbstractContactStore.d.ts +1 -2
- package/dist/contact/AbstractContactStore.d.ts.map +1 -1
- package/dist/contact/AbstractContactStore.js.map +1 -1
- package/dist/contact/ContactStore.d.ts +1 -2
- package/dist/contact/ContactStore.d.ts.map +1 -1
- package/dist/contact/ContactStore.js +11 -11
- package/dist/contact/ContactStore.js.map +1 -1
- package/dist/entities/contact/ConnectionEntity.d.ts +1 -1
- package/dist/entities/contact/ConnectionEntity.d.ts.map +1 -1
- package/dist/entities/contact/ConnectionEntity.js +4 -4
- package/dist/entities/contact/ConnectionEntity.js.map +1 -1
- package/dist/entities/contact/ContactEntity.d.ts +1 -1
- package/dist/entities/contact/ContactEntity.d.ts.map +1 -1
- package/dist/entities/contact/ContactEntity.js +2 -5
- package/dist/entities/contact/ContactEntity.js.map +1 -1
- package/dist/entities/contact/CorrelationIdentifierEntity.d.ts +1 -1
- package/dist/entities/contact/CorrelationIdentifierEntity.d.ts.map +1 -1
- package/dist/entities/contact/CorrelationIdentifierEntity.js +3 -4
- package/dist/entities/contact/CorrelationIdentifierEntity.js.map +1 -1
- package/dist/entities/contact/DidAuthConfigEntity.d.ts +1 -1
- package/dist/entities/contact/DidAuthConfigEntity.d.ts.map +1 -1
- package/dist/entities/contact/IdentityEntity.d.ts +2 -2
- package/dist/entities/contact/IdentityEntity.d.ts.map +1 -1
- package/dist/entities/contact/IdentityEntity.js +4 -7
- package/dist/entities/contact/IdentityEntity.js.map +1 -1
- package/dist/entities/contact/IdentityMetadataItemEntity.d.ts +1 -1
- package/dist/entities/contact/IdentityMetadataItemEntity.d.ts.map +1 -1
- package/dist/entities/contact/IdentityMetadataItemEntity.js +1 -2
- package/dist/entities/contact/IdentityMetadataItemEntity.js.map +1 -1
- package/dist/entities/contact/OpenIdConfigEntity.d.ts +1 -1
- package/dist/entities/contact/OpenIdConfigEntity.d.ts.map +1 -1
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.d.ts +11 -0
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.js +74 -0
- package/dist/entities/issuanceBranding/BackgroundAttributesEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/BaseLocaleBrandingEntity.d.ts +18 -0
- package/dist/entities/issuanceBranding/BaseLocaleBrandingEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/BaseLocaleBrandingEntity.js +120 -0
- package/dist/entities/issuanceBranding/BaseLocaleBrandingEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.d.ts +15 -0
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.js +102 -0
- package/dist/entities/issuanceBranding/CredentialBrandingEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.d.ts +9 -0
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.js +49 -0
- package/dist/entities/issuanceBranding/CredentialLocaleBrandingEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/ImageAttributesEntity.d.ts +14 -0
- package/dist/entities/issuanceBranding/ImageAttributesEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/ImageAttributesEntity.js +92 -0
- package/dist/entities/issuanceBranding/ImageAttributesEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.d.ts +9 -0
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.js +39 -0
- package/dist/entities/issuanceBranding/ImageDimensionsEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.d.ts +14 -0
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.js +95 -0
- package/dist/entities/issuanceBranding/IssuerBrandingEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.d.ts +9 -0
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.js +49 -0
- package/dist/entities/issuanceBranding/IssuerLocaleBrandingEntity.js.map +1 -0
- package/dist/entities/issuanceBranding/TextAttributesEntity.d.ts +9 -0
- package/dist/entities/issuanceBranding/TextAttributesEntity.d.ts.map +1 -0
- package/dist/entities/issuanceBranding/TextAttributesEntity.js +62 -0
- package/dist/entities/issuanceBranding/TextAttributesEntity.js.map +1 -0
- package/dist/entities/validators/index.d.ts +7 -0
- package/dist/entities/validators/index.d.ts.map +1 -0
- package/dist/entities/validators/index.js +27 -0
- package/dist/entities/validators/index.js.map +1 -0
- package/dist/index.d.ts +15 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +45 -5
- package/dist/index.js.map +1 -1
- package/dist/issuanceBranding/AbstractIssuanceBrandingStore.d.ts +20 -0
- package/dist/issuanceBranding/AbstractIssuanceBrandingStore.d.ts.map +1 -0
- package/dist/issuanceBranding/AbstractIssuanceBrandingStore.js +7 -0
- package/dist/issuanceBranding/AbstractIssuanceBrandingStore.js.map +1 -0
- package/dist/issuanceBranding/IssuanceBrandingStore.d.ts +31 -0
- package/dist/issuanceBranding/IssuanceBrandingStore.d.ts.map +1 -0
- package/dist/issuanceBranding/IssuanceBrandingStore.js +375 -0
- package/dist/issuanceBranding/IssuanceBrandingStore.js.map +1 -0
- package/dist/migrations/generic/1-CreateContacts.js +1 -1
- package/dist/migrations/generic/1-CreateContacts.js.map +1 -1
- package/dist/migrations/generic/1-CreateIssuanceBranding.d.ts +7 -0
- package/dist/migrations/generic/1-CreateIssuanceBranding.d.ts.map +1 -0
- package/dist/migrations/generic/1-CreateIssuanceBranding.js +72 -0
- package/dist/migrations/generic/1-CreateIssuanceBranding.js.map +1 -0
- package/dist/migrations/generic/index.d.ts.map +1 -1
- package/dist/migrations/generic/index.js +2 -1
- package/dist/migrations/generic/index.js.map +1 -1
- package/dist/migrations/postgres/1685628974232-CreateIssuanceBranding.d.ts +7 -0
- package/dist/migrations/postgres/1685628974232-CreateIssuanceBranding.d.ts.map +1 -0
- package/dist/migrations/postgres/1685628974232-CreateIssuanceBranding.js +67 -0
- package/dist/migrations/postgres/1685628974232-CreateIssuanceBranding.js.map +1 -0
- package/dist/migrations/sqlite/1659463069549-CreateContacts.d.ts.map +1 -1
- package/dist/migrations/sqlite/1659463069549-CreateContacts.js.map +1 -1
- package/dist/migrations/sqlite/1685628973231-CreateIssuanceBranding.d.ts +7 -0
- package/dist/migrations/sqlite/1685628973231-CreateIssuanceBranding.d.ts.map +1 -0
- package/dist/migrations/sqlite/1685628973231-CreateIssuanceBranding.js +89 -0
- package/dist/migrations/sqlite/1685628973231-CreateIssuanceBranding.js.map +1 -0
- package/dist/types/{IAbstractContactStore.d.ts → contact/IAbstractContactStore.d.ts} +2 -2
- package/dist/types/contact/IAbstractContactStore.d.ts.map +1 -0
- package/dist/types/contact/IAbstractContactStore.js.map +1 -0
- package/dist/types/contact/contact.d.ts.map +1 -0
- package/dist/types/contact/contact.js.map +1 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +21 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/issuanceBranding/IAbstractIssuanceBrandingStore.d.ts +59 -0
- package/dist/types/issuanceBranding/IAbstractIssuanceBrandingStore.d.ts.map +1 -0
- package/dist/types/issuanceBranding/IAbstractIssuanceBrandingStore.js +3 -0
- package/dist/types/issuanceBranding/IAbstractIssuanceBrandingStore.js.map +1 -0
- package/dist/types/issuanceBranding/issuanceBranding.d.ts +115 -0
- package/dist/types/issuanceBranding/issuanceBranding.d.ts.map +1 -0
- package/dist/types/issuanceBranding/issuanceBranding.js +3 -0
- package/dist/types/issuanceBranding/issuanceBranding.js.map +1 -0
- package/package.json +3 -3
- package/src/__tests__/contact.entities.test.ts +31 -31
- package/src/__tests__/contact.store.test.ts +32 -32
- package/src/__tests__/issuanceBranding.entities.test.ts +844 -0
- package/src/__tests__/issuanceBranding.store.test.ts +1884 -0
- package/src/contact/AbstractContactStore.ts +3 -2
- package/src/contact/ContactStore.ts +2 -4
- package/src/entities/contact/ConnectionEntity.ts +1 -1
- package/src/entities/contact/ContactEntity.ts +5 -7
- package/src/entities/contact/CorrelationIdentifierEntity.ts +4 -4
- package/src/entities/contact/DidAuthConfigEntity.ts +1 -1
- package/src/entities/contact/IdentityEntity.ts +6 -8
- package/src/entities/contact/IdentityMetadataItemEntity.ts +4 -4
- package/src/entities/contact/OpenIdConfigEntity.ts +1 -1
- package/src/entities/issuanceBranding/BackgroundAttributesEntity.ts +42 -0
- package/src/entities/issuanceBranding/BaseLocaleBrandingEntity.ts +86 -0
- package/src/entities/issuanceBranding/CredentialBrandingEntity.ts +78 -0
- package/src/entities/issuanceBranding/CredentialLocaleBrandingEntity.ts +33 -0
- package/src/entities/issuanceBranding/ImageAttributesEntity.ts +57 -0
- package/src/entities/issuanceBranding/ImageDimensionsEntity.ts +22 -0
- package/src/entities/issuanceBranding/IssuerBrandingEntity.ts +72 -0
- package/src/entities/issuanceBranding/IssuerLocaleBrandingEntity.ts +33 -0
- package/src/entities/issuanceBranding/TextAttributesEntity.ts +31 -0
- package/src/entities/validators/index.ts +16 -0
- package/src/index.ts +42 -5
- package/src/issuanceBranding/AbstractIssuanceBrandingStore.ts +41 -0
- package/src/issuanceBranding/IssuanceBrandingStore.ts +544 -0
- package/src/migrations/generic/1-CreateContacts.ts +1 -1
- package/src/migrations/generic/1-CreateIssuanceBranding.ts +54 -0
- package/src/migrations/generic/index.ts +2 -1
- package/src/migrations/postgres/1685628974232-CreateIssuanceBranding.ts +83 -0
- package/src/migrations/sqlite/1659463069549-CreateContacts.ts +0 -1
- package/src/migrations/sqlite/1685628973231-CreateIssuanceBranding.ts +119 -0
- package/src/types/{IAbstractContactStore.ts → contact/IAbstractContactStore.ts} +3 -2
- package/src/types/index.ts +4 -0
- package/src/types/issuanceBranding/IAbstractIssuanceBrandingStore.ts +85 -0
- package/src/types/issuanceBranding/issuanceBranding.ts +120 -0
- package/dist/types/IAbstractContactStore.d.ts.map +0 -1
- package/dist/types/IAbstractContactStore.js.map +0 -1
- package/dist/types/contact.d.ts.map +0 -1
- package/dist/types/contact.js.map +0 -1
- /package/dist/types/{IAbstractContactStore.js → contact/IAbstractContactStore.js} +0 -0
- /package/dist/types/{contact.d.ts → contact/contact.d.ts} +0 -0
- /package/dist/types/{contact.js → contact/contact.js} +0 -0
- /package/src/types/{contact.ts → contact/contact.ts} +0 -0
|
@@ -31,7 +31,7 @@ export class CreateContacts1659463079429 implements MigrationInterface {
|
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
34
|
-
debug('reverting contacts tables')
|
|
34
|
+
debug('migration: reverting contacts tables')
|
|
35
35
|
const dbType = queryRunner.connection.driver.options.type
|
|
36
36
|
if (dbType === 'postgres') {
|
|
37
37
|
debug('using postgres migration file')
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { MigrationInterface, QueryRunner } from 'typeorm'
|
|
2
|
+
import Debug from 'debug'
|
|
3
|
+
import { CreateIssuanceBranding1685628974232 } from '../postgres/1685628974232-CreateIssuanceBranding'
|
|
4
|
+
import { CreateIssuanceBranding1685628973231 } from '../sqlite/1685628973231-CreateIssuanceBranding'
|
|
5
|
+
|
|
6
|
+
const debug = Debug('sphereon:ssi-sdk:migrations')
|
|
7
|
+
|
|
8
|
+
export class CreateIssuanceBranding1659463079429 implements MigrationInterface {
|
|
9
|
+
name = 'CreateIssuanceBranding1659463079429'
|
|
10
|
+
|
|
11
|
+
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
12
|
+
debug('migration: creating issuance branding tables')
|
|
13
|
+
const dbType = queryRunner.connection.driver.options.type
|
|
14
|
+
if (dbType === 'postgres') {
|
|
15
|
+
debug('using postgres migration file')
|
|
16
|
+
const mig = new CreateIssuanceBranding1685628974232()
|
|
17
|
+
const up = await mig.up(queryRunner)
|
|
18
|
+
debug('Migration statements executed')
|
|
19
|
+
return up
|
|
20
|
+
} else if (dbType === 'sqlite' || 'react-native') {
|
|
21
|
+
debug('using sqlite/react-native migration file')
|
|
22
|
+
const mig = new CreateIssuanceBranding1685628973231()
|
|
23
|
+
const up = await mig.up(queryRunner)
|
|
24
|
+
debug('Migration statements executed')
|
|
25
|
+
return up
|
|
26
|
+
} else {
|
|
27
|
+
return Promise.reject(
|
|
28
|
+
"Migrations are currently only supported for sqlite, react-native and postgres. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now"
|
|
29
|
+
)
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
34
|
+
debug('migration: reverting issuance branding tables')
|
|
35
|
+
const dbType = queryRunner.connection.driver.options.type
|
|
36
|
+
if (dbType === 'postgres') {
|
|
37
|
+
debug('using postgres migration file')
|
|
38
|
+
const mig = new CreateIssuanceBranding1685628974232()
|
|
39
|
+
const down = await mig.down(queryRunner)
|
|
40
|
+
debug('Migration statements executed')
|
|
41
|
+
return down
|
|
42
|
+
} else if (dbType === 'sqlite' || 'react-native') {
|
|
43
|
+
debug('using sqlite/react-native migration file')
|
|
44
|
+
const mig = new CreateIssuanceBranding1685628973231()
|
|
45
|
+
const down = await mig.down(queryRunner)
|
|
46
|
+
debug('Migration statements executed')
|
|
47
|
+
return down
|
|
48
|
+
} else {
|
|
49
|
+
return Promise.reject(
|
|
50
|
+
"Migrations are currently only supported for sqlite, react-native and postgres. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now"
|
|
51
|
+
)
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { CreateContacts1659463079429 } from './1-CreateContacts'
|
|
2
|
+
import { CreateIssuanceBranding1659463079429 } from './1-CreateIssuanceBranding'
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* The migrations array that SHOULD be used when initializing a TypeORM database connection.
|
|
@@ -7,4 +8,4 @@ import { CreateContacts1659463079429 } from './1-CreateContacts'
|
|
|
7
8
|
*
|
|
8
9
|
* @public
|
|
9
10
|
*/
|
|
10
|
-
export const DataStoreMigrations = [CreateContacts1659463079429]
|
|
11
|
+
export const DataStoreMigrations = [CreateContacts1659463079429, CreateIssuanceBranding1659463079429]
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { MigrationInterface, QueryRunner } from 'typeorm'
|
|
2
|
+
|
|
3
|
+
export class CreateIssuanceBranding1685628974232 implements MigrationInterface {
|
|
4
|
+
name = 'CreateIssuanceBranding1685628974232'
|
|
5
|
+
|
|
6
|
+
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
7
|
+
await queryRunner.query(
|
|
8
|
+
`CREATE TABLE "ImageDimensions" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "width" integer NOT NULL, "height" integer NOT NULL, CONSTRAINT "PK_ImageDimensions_id" PRIMARY KEY ("id"))`
|
|
9
|
+
)
|
|
10
|
+
await queryRunner.query(
|
|
11
|
+
`CREATE TABLE "ImageAttributes" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "uri" character varying(255), "dataUri" character varying(255), "mediaType" character varying(255), "alt" character varying(255), "dimensionsId" uuid, CONSTRAINT "UQ_dimensionsId" UNIQUE ("dimensionsId"), CONSTRAINT "PK_ImageAttributes_id" PRIMARY KEY ("id"))`
|
|
12
|
+
)
|
|
13
|
+
await queryRunner.query(
|
|
14
|
+
`CREATE TABLE "BackgroundAttributes" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "color" character varying(255), "imageId" uuid, CONSTRAINT "UQ_imageId" UNIQUE ("imageId"), CONSTRAINT "PK_BackgroundAttributes_id" PRIMARY KEY ("id"))`
|
|
15
|
+
)
|
|
16
|
+
await queryRunner.query(
|
|
17
|
+
`CREATE TABLE "TextAttributes" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "color" character varying(255), CONSTRAINT "PK_TextAttributes_id" PRIMARY KEY ("id"))`
|
|
18
|
+
)
|
|
19
|
+
await queryRunner.query(
|
|
20
|
+
`CREATE TABLE "BaseLocaleBranding" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "alias" character varying(255), "locale" character varying(255) NOT NULL, "description" character varying(255), "created_at" TIMESTAMP NOT NULL DEFAULT now(), "last_updated_at" TIMESTAMP NOT NULL DEFAULT now(), "credentialBrandingId" uuid, "issuerBrandingId" uuid, "type" character varying NOT NULL, "logoId" uuid, "backgroundId" uuid, "textId" uuid, CONSTRAINT "UQ_logoId" UNIQUE ("logoId"), CONSTRAINT "UQ_backgroundId" UNIQUE ("backgroundId"), CONSTRAINT "UQ_textId" UNIQUE ("textId"), CONSTRAINT "PK_BaseLocaleBranding_id" PRIMARY KEY ("id"))`
|
|
21
|
+
)
|
|
22
|
+
await queryRunner.query(
|
|
23
|
+
`CREATE UNIQUE INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale" ON "BaseLocaleBranding" ("credentialBrandingId", "locale")`
|
|
24
|
+
)
|
|
25
|
+
await queryRunner.query(
|
|
26
|
+
`CREATE UNIQUE INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale" ON "BaseLocaleBranding" ("issuerBrandingId", "locale")`
|
|
27
|
+
)
|
|
28
|
+
await queryRunner.query(`CREATE INDEX "IDX_BaseLocaleBranding_type" ON "BaseLocaleBranding" ("type")`)
|
|
29
|
+
await queryRunner.query(
|
|
30
|
+
`CREATE TABLE "CredentialBranding" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "vcHash" character varying(255) NOT NULL, "issuerCorrelationId" character varying(255) NOT NULL, "created_at" TIMESTAMP NOT NULL DEFAULT now(), "last_updated_at" TIMESTAMP NOT NULL DEFAULT now(), CONSTRAINT "UQ_vcHash" UNIQUE ("vcHash"), CONSTRAINT "PK_CredentialBranding_id" PRIMARY KEY ("id"))`
|
|
31
|
+
)
|
|
32
|
+
await queryRunner.query(`CREATE INDEX "IDX_CredentialBrandingEntity_issuerCorrelationId" ON "CredentialBranding" ("issuerCorrelationId")`)
|
|
33
|
+
await queryRunner.query(`CREATE INDEX "IDX_CredentialBrandingEntity_vcHash" ON "CredentialBranding" ("vcHash")`)
|
|
34
|
+
await queryRunner.query(
|
|
35
|
+
`CREATE TABLE "IssuerBranding" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "issuerCorrelationId" character varying(255) NOT NULL, "created_at" TIMESTAMP NOT NULL DEFAULT now(), "last_updated_at" TIMESTAMP NOT NULL DEFAULT now(), CONSTRAINT "UQ_issuerCorrelationId" UNIQUE ("issuerCorrelationId"), CONSTRAINT "PK_IssuerBranding_id" PRIMARY KEY ("id"))`
|
|
36
|
+
)
|
|
37
|
+
await queryRunner.query(`CREATE INDEX "IDX_IssuerBrandingEntity_issuerCorrelationId" ON "IssuerBranding" ("issuerCorrelationId")`)
|
|
38
|
+
await queryRunner.query(
|
|
39
|
+
`ALTER TABLE "ImageAttributes" ADD CONSTRAINT "FK_ImageAttributes_dimensionsId" FOREIGN KEY ("dimensionsId") REFERENCES "ImageDimensions"("id") ON DELETE CASCADE ON UPDATE NO ACTION`
|
|
40
|
+
)
|
|
41
|
+
await queryRunner.query(
|
|
42
|
+
`ALTER TABLE "BackgroundAttributes" ADD CONSTRAINT "FK_BackgroundAttributes_imageId" FOREIGN KEY ("imageId") REFERENCES "ImageAttributes"("id") ON DELETE CASCADE ON UPDATE NO ACTION`
|
|
43
|
+
)
|
|
44
|
+
await queryRunner.query(
|
|
45
|
+
`ALTER TABLE "BaseLocaleBranding" ADD CONSTRAINT "FK_BaseLocaleBranding_logoId" FOREIGN KEY ("logoId") REFERENCES "ImageAttributes"("id") ON DELETE CASCADE ON UPDATE NO ACTION`
|
|
46
|
+
)
|
|
47
|
+
await queryRunner.query(
|
|
48
|
+
`ALTER TABLE "BaseLocaleBranding" ADD CONSTRAINT "FK_BaseLocaleBranding_backgroundId" FOREIGN KEY ("backgroundId") REFERENCES "BackgroundAttributes"("id") ON DELETE CASCADE ON UPDATE NO ACTION`
|
|
49
|
+
)
|
|
50
|
+
await queryRunner.query(
|
|
51
|
+
`ALTER TABLE "BaseLocaleBranding" ADD CONSTRAINT "FK_BaseLocaleBranding_textId" FOREIGN KEY ("textId") REFERENCES "TextAttributes"("id") ON DELETE CASCADE ON UPDATE NO ACTION`
|
|
52
|
+
)
|
|
53
|
+
await queryRunner.query(
|
|
54
|
+
`ALTER TABLE "BaseLocaleBranding" ADD CONSTRAINT "FK_BaseLocaleBranding_credentialBrandingId" FOREIGN KEY ("credentialBrandingId") REFERENCES "CredentialBranding"("id") ON DELETE CASCADE ON UPDATE NO ACTION`
|
|
55
|
+
)
|
|
56
|
+
await queryRunner.query(
|
|
57
|
+
`ALTER TABLE "BaseLocaleBranding" ADD CONSTRAINT "FK_BaseLocaleBranding_issuerBrandingId" FOREIGN KEY ("issuerBrandingId") REFERENCES "IssuerBranding"("id") ON DELETE CASCADE ON UPDATE NO ACTION`
|
|
58
|
+
)
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
62
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP CONSTRAINT "FK_BaseLocaleBranding_issuerBrandingId"`)
|
|
63
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP CONSTRAINT "FK_BaseLocaleBranding_credentialBrandingId"`)
|
|
64
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP CONSTRAINT "FK_BaseLocaleBranding_textId"`)
|
|
65
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP CONSTRAINT "FK_BaseLocaleBranding_backgroundId"`)
|
|
66
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP CONSTRAINT "FK_BaseLocaleBranding_logoId"`)
|
|
67
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP CONSTRAINT "FK_BackgroundAttributes_imageId"`)
|
|
68
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP CONSTRAINT "FK_ImageAttributes_dimensionsId"`)
|
|
69
|
+
await queryRunner.query(`ALTER TABLE "IssuerBranding" DROP INDEX "IDX_IssuerBrandingEntity_issuerCorrelationId"`)
|
|
70
|
+
await queryRunner.query(`DROP TABLE "IssuerBranding"`)
|
|
71
|
+
await queryRunner.query(`ALTER TABLE "CredentialBranding" DROP INDEX "IDX_CredentialBrandingEntity_vcHash"`)
|
|
72
|
+
await queryRunner.query(`ALTER TABLE "CredentialBranding" DROP INDEX "IDX_CredentialBrandingEntity_issuerCorrelationId"`)
|
|
73
|
+
await queryRunner.query(`DROP TABLE "CredentialBranding"`)
|
|
74
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP INDEX "IDX_BaseLocaleBranding_type"`)
|
|
75
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale"`)
|
|
76
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" DROP INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale"`)
|
|
77
|
+
await queryRunner.query(`DROP TABLE "BaseLocaleBranding"`)
|
|
78
|
+
await queryRunner.query(`DROP TABLE "TextAttributes"`)
|
|
79
|
+
await queryRunner.query(`DROP TABLE "BackgroundAttributes"`)
|
|
80
|
+
await queryRunner.query(`DROP TABLE "ImageAttributes"`)
|
|
81
|
+
await queryRunner.query(`DROP TABLE "ImageDimensions"`)
|
|
82
|
+
}
|
|
83
|
+
}
|
|
@@ -99,7 +99,6 @@ export class CreateContacts1659463069549 implements MigrationInterface {
|
|
|
99
99
|
`INSERT INTO "CorrelationIdentifier"("id", "type", "correlation_id", "identityId") SELECT "id", "type", "correlation_id", "identityId" FROM "CorrelationIdentifier"`
|
|
100
100
|
)
|
|
101
101
|
await queryRunner.query(`DROP TABLE "temporary_CorrelationIdentifier"`)
|
|
102
|
-
|
|
103
102
|
await queryRunner.query(`DROP TABLE "Connection"`)
|
|
104
103
|
await queryRunner.query(`DROP TABLE "Identity"`)
|
|
105
104
|
await queryRunner.query(`DROP TABLE "IdentityMetadata"`)
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import { MigrationInterface, QueryRunner } from 'typeorm'
|
|
2
|
+
|
|
3
|
+
export class CreateIssuanceBranding1685628973231 implements MigrationInterface {
|
|
4
|
+
name = 'CreateIssuanceBranding1685628973231'
|
|
5
|
+
|
|
6
|
+
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
7
|
+
await queryRunner.query(`CREATE TABLE "ImageDimensions" ("id" varchar PRIMARY KEY NOT NULL, "width" integer NOT NULL, "height" integer NOT NULL)`)
|
|
8
|
+
await queryRunner.query(
|
|
9
|
+
`CREATE TABLE "ImageAttributes" ("id" varchar PRIMARY KEY NOT NULL, "uri" varchar(255), "dataUri" varchar(255), "mediaType" varchar(255), "alt" varchar(255), "dimensionsId" varchar, CONSTRAINT "UQ_dimensionsId" UNIQUE ("dimensionsId"))`
|
|
10
|
+
)
|
|
11
|
+
await queryRunner.query(
|
|
12
|
+
`CREATE TABLE "BackgroundAttributes" ("id" varchar PRIMARY KEY NOT NULL, "color" varchar(255), "imageId" varchar, CONSTRAINT "UQ_imageId" UNIQUE ("imageId"))`
|
|
13
|
+
)
|
|
14
|
+
await queryRunner.query(`CREATE TABLE "TextAttributes" ("id" varchar PRIMARY KEY NOT NULL, "color" varchar(255))`)
|
|
15
|
+
await queryRunner.query(
|
|
16
|
+
`CREATE TABLE "BaseLocaleBranding" ("id" varchar PRIMARY KEY NOT NULL, "alias" varchar(255), "locale" varchar(255) NOT NULL, "description" varchar(255), "created_at" datetime NOT NULL DEFAULT (datetime('now')), "last_updated_at" datetime NOT NULL DEFAULT (datetime('now')), "credentialBrandingId" varchar, "issuerBrandingId" varchar, "type" varchar NOT NULL, "logoId" varchar, "backgroundId" varchar, "textId" varchar, CONSTRAINT "UQ_logoId" UNIQUE ("logoId"), CONSTRAINT "UQ_backgroundId" UNIQUE ("backgroundId"), CONSTRAINT "UQ_textId" UNIQUE ("textId"))`
|
|
17
|
+
)
|
|
18
|
+
await queryRunner.query(
|
|
19
|
+
`CREATE UNIQUE INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale" ON "BaseLocaleBranding" ("credentialBrandingId", "locale")`
|
|
20
|
+
)
|
|
21
|
+
await queryRunner.query(
|
|
22
|
+
`CREATE UNIQUE INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale" ON "BaseLocaleBranding" ("issuerBrandingId", "locale")`
|
|
23
|
+
)
|
|
24
|
+
await queryRunner.query(`CREATE INDEX "IDX_BaseLocaleBranding_type" ON "BaseLocaleBranding" ("type")`)
|
|
25
|
+
await queryRunner.query(
|
|
26
|
+
`CREATE TABLE "CredentialBranding" ("id" varchar PRIMARY KEY NOT NULL, "vcHash" varchar(255) NOT NULL, "issuerCorrelationId" varchar(255) NOT NULL, "created_at" datetime NOT NULL DEFAULT (datetime('now')), "last_updated_at" datetime NOT NULL DEFAULT (datetime('now')), CONSTRAINT "UQ_vcHash" UNIQUE ("vcHash"))`
|
|
27
|
+
)
|
|
28
|
+
await queryRunner.query(`CREATE INDEX "IDX_CredentialBrandingEntity_issuerCorrelationId" ON "CredentialBranding" ("issuerCorrelationId")`)
|
|
29
|
+
await queryRunner.query(`CREATE INDEX "IDX_CredentialBrandingEntity_vcHash" ON "CredentialBranding" ("vcHash")`)
|
|
30
|
+
await queryRunner.query(
|
|
31
|
+
`CREATE TABLE "IssuerBranding" ("id" varchar PRIMARY KEY NOT NULL, "issuerCorrelationId" varchar(255) NOT NULL, "created_at" datetime NOT NULL DEFAULT (datetime('now')), "last_updated_at" datetime NOT NULL DEFAULT (datetime('now')), CONSTRAINT "UQ_issuerCorrelationId" UNIQUE ("issuerCorrelationId"))`
|
|
32
|
+
)
|
|
33
|
+
await queryRunner.query(`CREATE INDEX "IDX_IssuerBrandingEntity_issuerCorrelationId" ON "IssuerBranding" ("issuerCorrelationId")`)
|
|
34
|
+
await queryRunner.query(
|
|
35
|
+
`CREATE TABLE "temporary_ImageAttributes" ("id" varchar PRIMARY KEY NOT NULL, "uri" varchar(255), "dataUri" varchar(255), "mediaType" varchar(255), "alt" varchar(255), "dimensionsId" varchar, CONSTRAINT "UQ_dimensionsId" UNIQUE ("dimensionsId"), CONSTRAINT "FK_ImageAttributes_dimensionsId" FOREIGN KEY ("dimensionsId") REFERENCES "ImageDimensions" ("id") ON DELETE CASCADE ON UPDATE NO ACTION)`
|
|
36
|
+
)
|
|
37
|
+
await queryRunner.query(
|
|
38
|
+
`INSERT INTO "temporary_ImageAttributes"("id", "uri", "dataUri", "mediaType", "alt", "dimensionsId") SELECT "id", "uri", "dataUri", "mediaType", "alt", "dimensionsId" FROM "ImageAttributes"`
|
|
39
|
+
)
|
|
40
|
+
await queryRunner.query(`DROP TABLE "ImageAttributes"`)
|
|
41
|
+
await queryRunner.query(`ALTER TABLE "temporary_ImageAttributes" RENAME TO "ImageAttributes"`)
|
|
42
|
+
await queryRunner.query(
|
|
43
|
+
`CREATE TABLE "temporary_BackgroundAttributes" ("id" varchar PRIMARY KEY NOT NULL, "color" varchar(255), "imageId" varchar, CONSTRAINT "UQ_imageId" UNIQUE ("imageId"), CONSTRAINT "FK_BackgroundAttributes_imageId" FOREIGN KEY ("imageId") REFERENCES "ImageAttributes" ("id") ON DELETE CASCADE ON UPDATE NO ACTION)`
|
|
44
|
+
)
|
|
45
|
+
await queryRunner.query(
|
|
46
|
+
`INSERT INTO "temporary_BackgroundAttributes"("id", "color", "imageId") SELECT "id", "color", "imageId" FROM "BackgroundAttributes"`
|
|
47
|
+
)
|
|
48
|
+
await queryRunner.query(`DROP TABLE "BackgroundAttributes"`)
|
|
49
|
+
await queryRunner.query(`ALTER TABLE "temporary_BackgroundAttributes" RENAME TO "BackgroundAttributes"`)
|
|
50
|
+
await queryRunner.query(`DROP INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale"`)
|
|
51
|
+
await queryRunner.query(`DROP INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale"`)
|
|
52
|
+
await queryRunner.query(`DROP INDEX "IDX_BaseLocaleBranding_type"`)
|
|
53
|
+
await queryRunner.query(
|
|
54
|
+
`CREATE TABLE "temporary_BaseLocaleBranding" ("id" varchar PRIMARY KEY NOT NULL, "alias" varchar(255), "locale" varchar(255) NOT NULL, "description" varchar(255), "created_at" datetime NOT NULL DEFAULT (datetime('now')), "last_updated_at" datetime NOT NULL DEFAULT (datetime('now')), "credentialBrandingId" varchar, "issuerBrandingId" varchar, "type" varchar NOT NULL, "logoId" varchar, "backgroundId" varchar, "textId" varchar, CONSTRAINT "UQ_logoId" UNIQUE ("logoId"), CONSTRAINT "UQ_backgroundId" UNIQUE ("backgroundId"), CONSTRAINT "UQ_textId" UNIQUE ("textId"), CONSTRAINT "FK_BaseLocaleBranding_logoId" FOREIGN KEY ("logoId") REFERENCES "ImageAttributes" ("id") ON DELETE CASCADE ON UPDATE NO ACTION, CONSTRAINT "FK_BaseLocaleBranding_backgroundId" FOREIGN KEY ("backgroundId") REFERENCES "BackgroundAttributes" ("id") ON DELETE CASCADE ON UPDATE NO ACTION, CONSTRAINT "FK_BaseLocaleBranding_textId" FOREIGN KEY ("textId") REFERENCES "TextAttributes" ("id") ON DELETE CASCADE ON UPDATE NO ACTION, CONSTRAINT "FK_BaseLocaleBranding_credentialBrandingId" FOREIGN KEY ("credentialBrandingId") REFERENCES "CredentialBranding" ("id") ON DELETE CASCADE ON UPDATE NO ACTION, CONSTRAINT "FK_BaseLocaleBranding_issuerBrandingId" FOREIGN KEY ("issuerBrandingId") REFERENCES "IssuerBranding" ("id") ON DELETE CASCADE ON UPDATE NO ACTION)`
|
|
55
|
+
)
|
|
56
|
+
await queryRunner.query(
|
|
57
|
+
`INSERT INTO "temporary_BaseLocaleBranding"("id", "alias", "locale", "description", "created_at", "last_updated_at", "credentialBrandingId", "issuerBrandingId", "type", "logoId", "backgroundId", "textId") SELECT "id", "alias", "locale", "description", "created_at", "last_updated_at", "credentialBrandingId", "issuerBrandingId", "type", "logoId", "backgroundId", "textId" FROM "BaseLocaleBranding"`
|
|
58
|
+
)
|
|
59
|
+
await queryRunner.query(`DROP TABLE "BaseLocaleBranding"`)
|
|
60
|
+
await queryRunner.query(`ALTER TABLE "temporary_BaseLocaleBranding" RENAME TO "BaseLocaleBranding"`)
|
|
61
|
+
await queryRunner.query(
|
|
62
|
+
`CREATE UNIQUE INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale" ON "BaseLocaleBranding" ("credentialBrandingId", "locale")`
|
|
63
|
+
)
|
|
64
|
+
await queryRunner.query(
|
|
65
|
+
`CREATE UNIQUE INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale" ON "BaseLocaleBranding" ("issuerBrandingId", "locale")`
|
|
66
|
+
)
|
|
67
|
+
await queryRunner.query(`CREATE INDEX "IDX_BaseLocaleBranding_type" ON "BaseLocaleBranding" ("type")`)
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
71
|
+
await queryRunner.query(`DROP INDEX "IDX_BaseLocaleBranding_type"`)
|
|
72
|
+
await queryRunner.query(`DROP INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale"`)
|
|
73
|
+
await queryRunner.query(`DROP INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale"`)
|
|
74
|
+
await queryRunner.query(`ALTER TABLE "BaseLocaleBranding" RENAME TO "temporary_BaseLocaleBranding"`)
|
|
75
|
+
await queryRunner.query(
|
|
76
|
+
`CREATE TABLE "BaseLocaleBranding" ("id" varchar PRIMARY KEY NOT NULL, "alias" varchar(255), "locale" varchar(255) NOT NULL, "description" varchar(255), "created_at" datetime NOT NULL DEFAULT (datetime('now')), "last_updated_at" datetime NOT NULL DEFAULT (datetime('now')), "credentialBrandingId" varchar, "issuerBrandingId" varchar, "type" varchar NOT NULL, "logoId" varchar, "backgroundId" varchar, "textId" varchar, CONSTRAINT "UQ_logoId" UNIQUE ("logoId"), CONSTRAINT "UQ_backgroundId" UNIQUE ("backgroundId"), CONSTRAINT "UQ_textId" UNIQUE ("textId"))`
|
|
77
|
+
)
|
|
78
|
+
await queryRunner.query(
|
|
79
|
+
`INSERT INTO "BaseLocaleBranding"("id", "alias", "locale", "description", "created_at", "last_updated_at", "credentialBrandingId", "issuerBrandingId", "type", "logoId", "backgroundId", "textId") SELECT "id", "alias", "locale", "description", "created_at", "last_updated_at", "credentialBrandingId", "issuerBrandingId", "type", "logoId", "backgroundId", "textId" FROM "BaseLocaleBranding"`
|
|
80
|
+
)
|
|
81
|
+
await queryRunner.query(`DROP TABLE "temporary_BaseLocaleBranding"`)
|
|
82
|
+
await queryRunner.query(`CREATE INDEX "IDX_BaseLocaleBranding_type" ON "BaseLocaleBranding" ("type")`)
|
|
83
|
+
await queryRunner.query(
|
|
84
|
+
`CREATE UNIQUE INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale" ON "BaseLocaleBranding" ("issuerBrandingId", "locale")`
|
|
85
|
+
)
|
|
86
|
+
await queryRunner.query(
|
|
87
|
+
`CREATE UNIQUE INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale" ON "BaseLocaleBranding" ("credentialBrandingId", "locale")`
|
|
88
|
+
)
|
|
89
|
+
await queryRunner.query(`ALTER TABLE "BackgroundAttributes" RENAME TO "temporary_BackgroundAttributes"`)
|
|
90
|
+
await queryRunner.query(
|
|
91
|
+
`CREATE TABLE "BackgroundAttributes" ("id" varchar PRIMARY KEY NOT NULL, "color" varchar(255), "imageId" varchar, CONSTRAINT "UQ_imageId" UNIQUE ("imageId"))`
|
|
92
|
+
)
|
|
93
|
+
await queryRunner.query(
|
|
94
|
+
`INSERT INTO "BackgroundAttributes"("id", "color", "imageId") SELECT "id", "color", "imageId" FROM "BackgroundAttributes"`
|
|
95
|
+
)
|
|
96
|
+
await queryRunner.query(`DROP TABLE "temporary_BackgroundAttributes"`)
|
|
97
|
+
await queryRunner.query(`ALTER TABLE "ImageAttributes" RENAME TO "temporary_ImageAttributes"`)
|
|
98
|
+
await queryRunner.query(
|
|
99
|
+
`CREATE TABLE "ImageAttributes" ("id" varchar PRIMARY KEY NOT NULL, "uri" varchar(255), "dataUri" varchar(255), "mediaType" varchar(255), "alt" varchar(255), "dimensionsId" varchar, CONSTRAINT "UQ_dimensionsId" UNIQUE ("dimensionsId"))`
|
|
100
|
+
)
|
|
101
|
+
await queryRunner.query(
|
|
102
|
+
`INSERT INTO "ImageAttributes"("id", "uri", "dataUri", "mediaType", "alt", "dimensionsId") SELECT "id", "uri", "dataUri", "mediaType", "alt", "dimensionsId" FROM "ImageAttributes"`
|
|
103
|
+
)
|
|
104
|
+
await queryRunner.query(`DROP TABLE "temporary_ImageAttributes"`)
|
|
105
|
+
await queryRunner.query(`DROP INDEX "IDX_IssuerBrandingEntity_issuerCorrelationId"`)
|
|
106
|
+
await queryRunner.query(`DROP TABLE "IssuerBranding"`)
|
|
107
|
+
await queryRunner.query(`DROP INDEX "IDX_CredentialBrandingEntity_vcHash"`)
|
|
108
|
+
await queryRunner.query(`DROP INDEX "IDX_CredentialBrandingEntity_issuerCorrelationId"`)
|
|
109
|
+
await queryRunner.query(`DROP TABLE "CredentialBranding"`)
|
|
110
|
+
await queryRunner.query(`DROP INDEX "IDX_BaseLocaleBranding_type"`)
|
|
111
|
+
await queryRunner.query(`DROP INDEX "IDX_IssuerLocaleBrandingEntity_issuerBranding_locale"`)
|
|
112
|
+
await queryRunner.query(`DROP INDEX "IDX_CredentialLocaleBrandingEntity_credentialBranding_locale"`)
|
|
113
|
+
await queryRunner.query(`DROP TABLE "BaseLocaleBranding"`)
|
|
114
|
+
await queryRunner.query(`DROP TABLE "TextAttributes"`)
|
|
115
|
+
await queryRunner.query(`DROP TABLE "BackgroundAttributes"`)
|
|
116
|
+
await queryRunner.query(`DROP TABLE "ImageAttributes"`)
|
|
117
|
+
await queryRunner.query(`DROP TABLE "ImageDimensions"`)
|
|
118
|
+
}
|
|
119
|
+
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { FindOptionsWhere } from 'typeorm'
|
|
2
|
-
import { ContactEntity } from '
|
|
3
|
-
import { IdentityEntity } from '
|
|
2
|
+
import { ContactEntity } from '../../entities/contact/ContactEntity'
|
|
3
|
+
import { IdentityEntity } from '../../entities/contact/IdentityEntity'
|
|
4
4
|
import { IBasicIdentity, IContact, IIdentity } from './contact'
|
|
5
5
|
|
|
6
|
+
// TODO WAL-625 refactor types to use interfaces and not the entities as the store should be replaceable
|
|
6
7
|
export type FindContactArgs = FindOptionsWhere<ContactEntity>[]
|
|
7
8
|
export type FindIdentityArgs = FindOptionsWhere<IdentityEntity>[]
|
|
8
9
|
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import {
|
|
2
|
+
IBasicCredentialLocaleBranding,
|
|
3
|
+
IBasicIssuerLocaleBranding,
|
|
4
|
+
ICredentialBranding,
|
|
5
|
+
ICredentialLocaleBrandingFilter,
|
|
6
|
+
IIssuerBranding,
|
|
7
|
+
IIssuerBrandingFilter,
|
|
8
|
+
IIssuerLocaleBrandingFilter,
|
|
9
|
+
ILocaleBranding,
|
|
10
|
+
ICredentialBrandingFilter,
|
|
11
|
+
} from './issuanceBranding'
|
|
12
|
+
|
|
13
|
+
export type FindCredentialBrandingArgs = Array<ICredentialBrandingFilter>
|
|
14
|
+
export type FindCredentialLocaleBrandingArgs = Array<ICredentialLocaleBrandingFilter>
|
|
15
|
+
export type FindIssuerBrandingArgs = Array<IIssuerBrandingFilter>
|
|
16
|
+
export type FindIssuerLocaleBrandingArgs = Array<IIssuerLocaleBrandingFilter>
|
|
17
|
+
|
|
18
|
+
export interface IAddCredentialBrandingArgs {
|
|
19
|
+
vcHash: string
|
|
20
|
+
issuerCorrelationId: string
|
|
21
|
+
localeBranding: Array<IBasicCredentialLocaleBranding>
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export interface IGetCredentialBrandingArgs {
|
|
25
|
+
filter?: FindCredentialBrandingArgs
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface IUpdateCredentialBrandingArgs {
|
|
29
|
+
credentialBranding: Omit<ICredentialBranding, 'localeBranding' | 'createdAt' | 'lastUpdatedAt'>
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface IRemoveCredentialBrandingArgs {
|
|
33
|
+
filter: FindCredentialBrandingArgs
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface IAddCredentialLocaleBrandingArgs {
|
|
37
|
+
credentialBrandingId: string
|
|
38
|
+
localeBranding: Array<IBasicCredentialLocaleBranding>
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export interface IUpdateCredentialLocaleBrandingArgs {
|
|
42
|
+
localeBranding: Omit<ILocaleBranding, 'createdAt' | 'lastUpdatedAt'>
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export interface IRemoveCredentialLocaleBrandingArgs {
|
|
46
|
+
filter: FindCredentialLocaleBrandingArgs
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface IGetCredentialLocaleBrandingArgs {
|
|
50
|
+
filter?: FindCredentialLocaleBrandingArgs
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export interface IAddIssuerBrandingArgs {
|
|
54
|
+
issuerCorrelationId: string
|
|
55
|
+
localeBranding: Array<IBasicIssuerLocaleBranding>
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export interface IGetIssuerBrandingArgs {
|
|
59
|
+
filter?: FindIssuerBrandingArgs
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export interface IUpdateIssuerBrandingArgs {
|
|
63
|
+
issuerBranding: Omit<IIssuerBranding, 'localeBranding' | 'createdAt' | 'lastUpdatedAt'>
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export interface IRemoveIssuerBrandingArgs {
|
|
67
|
+
filter: FindIssuerBrandingArgs
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export interface IAddIssuerLocaleBrandingArgs {
|
|
71
|
+
issuerBrandingId: string
|
|
72
|
+
localeBranding: Array<IBasicIssuerLocaleBranding>
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export interface IUpdateIssuerLocaleBrandingArgs {
|
|
76
|
+
localeBranding: Omit<ILocaleBranding, 'createdAt' | 'lastUpdatedAt'>
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export interface IRemoveIssuerLocaleBrandingArgs {
|
|
80
|
+
filter: FindIssuerLocaleBrandingArgs
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export interface IGetIssuerLocaleBrandingArgs {
|
|
84
|
+
filter?: FindIssuerLocaleBrandingArgs
|
|
85
|
+
}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
export interface ILocaleBranding {
|
|
2
|
+
id: string
|
|
3
|
+
alias?: string
|
|
4
|
+
locale?: string
|
|
5
|
+
logo?: IImageAttributes
|
|
6
|
+
description?: string
|
|
7
|
+
background?: IBackgroundAttributes
|
|
8
|
+
text?: ITextAttributes
|
|
9
|
+
createdAt: Date
|
|
10
|
+
lastUpdatedAt: Date
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface IImageAttributes {
|
|
14
|
+
id: string
|
|
15
|
+
uri?: string
|
|
16
|
+
dataUri?: string
|
|
17
|
+
mediaType?: string
|
|
18
|
+
alt?: string
|
|
19
|
+
dimensions?: IImageDimensions
|
|
20
|
+
}
|
|
21
|
+
export interface IBasicImageAttributes extends Omit<IImageAttributes, 'id' | 'dimensions'> {
|
|
22
|
+
dimensions?: IBasicImageDimensions
|
|
23
|
+
}
|
|
24
|
+
export interface IPartialImageAttributes extends Partial<Omit<IImageAttributes, 'dimensions'>> {
|
|
25
|
+
dimensions?: IPartialImageDimensions
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface IBackgroundAttributes {
|
|
29
|
+
id: string
|
|
30
|
+
color?: string
|
|
31
|
+
image?: IImageAttributes
|
|
32
|
+
}
|
|
33
|
+
export interface IBasicBackgroundAttributes extends Omit<IBackgroundAttributes, 'id' | 'image'> {
|
|
34
|
+
image?: IBasicImageAttributes
|
|
35
|
+
}
|
|
36
|
+
export interface IPartialBackgroundAttributes extends Partial<Omit<IBackgroundAttributes, 'image'>> {
|
|
37
|
+
image?: IPartialImageAttributes
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface ITextAttributes {
|
|
41
|
+
id: string
|
|
42
|
+
color?: string
|
|
43
|
+
}
|
|
44
|
+
export interface IBasicTextAttributes extends Omit<ITextAttributes, 'id'> {}
|
|
45
|
+
export interface IPartialTextAttributes extends Partial<ITextAttributes> {}
|
|
46
|
+
|
|
47
|
+
export interface IImageDimensions {
|
|
48
|
+
id: string
|
|
49
|
+
width: number
|
|
50
|
+
height: number
|
|
51
|
+
}
|
|
52
|
+
export interface IBasicImageDimensions extends Omit<IImageDimensions, 'id'> {}
|
|
53
|
+
export interface IPartialImageDimensions extends Partial<IImageDimensions> {}
|
|
54
|
+
|
|
55
|
+
export interface ICredentialLocaleBranding extends ILocaleBranding {}
|
|
56
|
+
export interface IBasicCredentialLocaleBranding
|
|
57
|
+
extends Omit<ICredentialLocaleBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'logo' | 'background' | 'text'> {
|
|
58
|
+
logo?: IBasicImageAttributes
|
|
59
|
+
background?: IBasicBackgroundAttributes
|
|
60
|
+
text?: IBasicTextAttributes
|
|
61
|
+
}
|
|
62
|
+
export interface IPartialCredentialLocaleBranding extends Partial<Omit<ICredentialLocaleBranding, 'logo' | 'background' | 'text'>> {
|
|
63
|
+
logo?: IPartialImageAttributes
|
|
64
|
+
background?: IPartialBackgroundAttributes
|
|
65
|
+
text?: IPartialTextAttributes
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export interface ICredentialBranding {
|
|
69
|
+
id: string
|
|
70
|
+
issuerCorrelationId: string
|
|
71
|
+
vcHash: string
|
|
72
|
+
localeBranding: Array<ICredentialLocaleBranding>
|
|
73
|
+
createdAt: Date
|
|
74
|
+
lastUpdatedAt: Date
|
|
75
|
+
}
|
|
76
|
+
export interface IBasicCredentialBranding extends Omit<ICredentialBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'localeBranding'> {
|
|
77
|
+
localeBranding: Array<IBasicCredentialLocaleBranding>
|
|
78
|
+
}
|
|
79
|
+
export interface IPartialCredentialBranding extends Partial<Omit<ICredentialBranding, 'localeBranding'>> {
|
|
80
|
+
localeBranding?: IPartialCredentialLocaleBranding
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export interface IIssuerLocaleBranding extends ILocaleBranding {}
|
|
84
|
+
export interface IBasicIssuerLocaleBranding
|
|
85
|
+
extends Omit<IIssuerLocaleBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'logo' | 'background' | 'text'> {
|
|
86
|
+
logo?: IBasicImageAttributes
|
|
87
|
+
background?: IBasicBackgroundAttributes
|
|
88
|
+
text?: IBasicTextAttributes
|
|
89
|
+
}
|
|
90
|
+
export interface IPartialIssuerLocaleBranding extends Partial<Omit<IIssuerLocaleBranding, 'logo' | 'background' | 'text'>> {
|
|
91
|
+
logo?: IPartialImageAttributes
|
|
92
|
+
background?: IPartialBackgroundAttributes
|
|
93
|
+
text?: IPartialTextAttributes
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export interface IIssuerBranding {
|
|
97
|
+
id: string
|
|
98
|
+
issuerCorrelationId: string
|
|
99
|
+
localeBranding: Array<IIssuerLocaleBranding>
|
|
100
|
+
createdAt: Date
|
|
101
|
+
lastUpdatedAt: Date
|
|
102
|
+
}
|
|
103
|
+
export interface IBasicIssuerBranding extends Omit<IIssuerBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'localeBranding'> {
|
|
104
|
+
localeBranding: Array<IBasicIssuerLocaleBranding>
|
|
105
|
+
}
|
|
106
|
+
export interface IPartialIssuerBranding extends Partial<Omit<ICredentialBranding, 'localeBranding'>> {
|
|
107
|
+
localeBranding?: IPartialIssuerLocaleBranding
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export interface ICredentialBrandingFilter extends IPartialCredentialBranding {}
|
|
111
|
+
|
|
112
|
+
export interface ICredentialLocaleBrandingFilter extends IPartialCredentialLocaleBranding {
|
|
113
|
+
credentialBranding?: IPartialCredentialBranding
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export interface IIssuerBrandingFilter extends IPartialIssuerBranding {}
|
|
117
|
+
|
|
118
|
+
export interface IIssuerLocaleBrandingFilter extends IPartialIssuerLocaleBranding {
|
|
119
|
+
issuerBranding?: IPartialIssuerBranding
|
|
120
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IAbstractContactStore.d.ts","sourceRoot":"","sources":["../../src/types/IAbstractContactStore.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAA;AACjE,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAA;AACnE,OAAO,EAAE,cAAc,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,WAAW,CAAA;AAE/D,MAAM,MAAM,eAAe,GAAG,gBAAgB,CAAC,aAAa,CAAC,EAAE,CAAA;AAC/D,MAAM,MAAM,gBAAgB,GAAG,gBAAgB,CAAC,cAAc,CAAC,EAAE,CAAA;AAEjE,MAAM,WAAW,eAAe;IAC9B,SAAS,EAAE,MAAM,CAAA;CAClB;AAED,MAAM,WAAW,gBAAgB;IAC/B,MAAM,CAAC,EAAE,eAAe,CAAA;CACzB;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,EAAE,MAAM,CAAA;IACb,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,UAAU,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,CAAA;CACnC;AAED,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,IAAI,CAAC,QAAQ,EAAE,YAAY,GAAG,WAAW,GAAG,eAAe,CAAC,CAAA;CACtE;AAED,MAAM,WAAW,kBAAkB;IACjC,SAAS,EAAE,MAAM,CAAA;CAClB;AAED,MAAM,WAAW,gBAAgB;IAC/B,UAAU,EAAE,MAAM,CAAA;CACnB;AAED,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,gBAAgB,CAAA;CAC1B;AAED,MAAM,WAAW,gBAAgB;IAC/B,SAAS,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,cAAc,CAAA;CACzB;AAED,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,WAAW,mBAAmB;IAClC,UAAU,EAAE,MAAM,CAAA;CACnB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IAbstractContactStore.js","sourceRoot":"","sources":["../../src/types/IAbstractContactStore.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contact.d.ts","sourceRoot":"","sources":["../../src/types/contact.ts"],"names":[],"mappings":"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"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contact.js","sourceRoot":"","sources":["../../src/types/contact.ts"],"names":[],"mappings":";;;AAEA,IAAY,gBAIX;AAJD,WAAY,gBAAgB;IAC1B,qCAAiB,CAAA;IACjB,yCAAqB,CAAA;IACrB,qCAAiB,CAAA;AACnB,CAAC,EAJW,gBAAgB,GAAhB,wBAAgB,KAAhB,wBAAgB,QAI3B;AAED,IAAY,kBAIX;AAJD,WAAY,kBAAkB;IAC5B,6CAAuB,CAAA;IACvB,uCAAiB,CAAA;IACjB,2DAAqC,CAAA;AACvC,CAAC,EAJW,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAI7B;AAED,IAAY,yBAGX;AAHD,WAAY,yBAAyB;IACnC,wCAAW,CAAA;IACX,wCAAW,CAAA;AACb,CAAC,EAHW,yBAAyB,GAAzB,iCAAyB,KAAzB,iCAAyB,QAGpC"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|