@shotstack/schemas 1.8.7 → 1.9.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 +89 -89
- package/dist/api.bundled.json +26 -0
- package/dist/json-schema/asset.json +45 -2
- package/dist/json-schema/clip.json +45 -2
- package/dist/json-schema/edit.json +45 -2
- package/dist/json-schema/rich-caption-active-font.json +18 -1
- package/dist/json-schema/rich-caption-active.json +105 -1
- package/dist/json-schema/rich-caption-asset.json +45 -2
- package/dist/json-schema/schemas.json +48 -2
- package/dist/json-schema/timeline.json +45 -2
- package/dist/json-schema/track.json +45 -2
- package/dist/schema.d.ts +16 -0
- package/dist/zod/zod.gen.cjs +1091 -925
- package/dist/zod/zod.gen.d.ts +1220 -344
- package/dist/zod/zod.gen.js +1092 -926
- package/dist/zod/zod.gen.ts +1601 -1667
- package/package.json +95 -79
package/README.md
CHANGED
|
@@ -1,89 +1,89 @@
|
|
|
1
|
-
# @shotstack/schemas
|
|
2
|
-
|
|
3
|
-
Centralized OpenAPI schemas and TypeScript types for the Shotstack API
|
|
4
|
-
|
|
5
|
-
## Installation
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
npm install @shotstack/schemas zod
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
## Usage
|
|
12
|
-
|
|
13
|
-
### TypeScript Types
|
|
14
|
-
|
|
15
|
-
```typescript
|
|
16
|
-
import type { components } from '@shotstack/schemas';
|
|
17
|
-
|
|
18
|
-
type Edit = components['schemas']['Edit'];
|
|
19
|
-
type Timeline = components['schemas']['Timeline'];
|
|
20
|
-
type Clip = components['schemas']['Clip'];
|
|
21
|
-
type Output = components['schemas']['Output'];
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
### Zod Schemas
|
|
25
|
-
|
|
26
|
-
```typescript
|
|
27
|
-
import { z } from 'zod';
|
|
28
|
-
import { richTextAssetSchema, editSchema, timelineSchema } from '@shotstack/schemas/zod';
|
|
29
|
-
|
|
30
|
-
const result = richTextAssetSchema.safeParse(inputData);
|
|
31
|
-
if (result.success) {
|
|
32
|
-
console.log(result.data);
|
|
33
|
-
}
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
### Extending Schemas
|
|
37
|
-
|
|
38
|
-
```typescript
|
|
39
|
-
import { z } from 'zod';
|
|
40
|
-
import { richTextAssetSchema } from '@shotstack/schemas/zod';
|
|
41
|
-
|
|
42
|
-
const ExtendedAsset = richTextAssetSchema.extend({
|
|
43
|
-
customFonts: z.array(z.object({
|
|
44
|
-
src: z.string().url(),
|
|
45
|
-
family: z.string(),
|
|
46
|
-
})).optional(),
|
|
47
|
-
border: z.object({
|
|
48
|
-
width: z.number().min(0),
|
|
49
|
-
color: z.string(),
|
|
50
|
-
}).optional(),
|
|
51
|
-
});
|
|
52
|
-
|
|
53
|
-
type ExtendedAssetType = z.infer<typeof ExtendedAsset>;
|
|
54
|
-
```
|
|
55
|
-
|
|
56
|
-
### Custom Validation
|
|
57
|
-
|
|
58
|
-
```typescript
|
|
59
|
-
import { richTextAnimationSchema } from '@shotstack/schemas/zod';
|
|
60
|
-
|
|
61
|
-
const AnimationWithDirection = richTextAnimationSchema.refine(
|
|
62
|
-
(data) => {
|
|
63
|
-
if (data.preset === 'slideIn' && !data.direction) {
|
|
64
|
-
return false;
|
|
65
|
-
}
|
|
66
|
-
return true;
|
|
67
|
-
},
|
|
68
|
-
{ message: 'direction is required for slideIn preset' }
|
|
69
|
-
);
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
## Available Schemas
|
|
73
|
-
|
|
74
|
-
- Edit, Timeline, Track, Clip, Output
|
|
75
|
-
- Assets: VideoAsset, ImageAsset, AudioAsset, HtmlAsset, TextAsset, TitleAsset, LumaAsset, CaptionAsset, ShapeAsset, RichTextAsset
|
|
76
|
-
- Destinations: ShotstackDestination, S3Destination, MuxDestination, VimeoDestination, GoogleDriveDestination, GoogleCloudStorageDestination
|
|
77
|
-
- Transforms, Transitions, Fonts, MergeFields, and more
|
|
78
|
-
|
|
79
|
-
## Development
|
|
80
|
-
|
|
81
|
-
```bash
|
|
82
|
-
pnpm install
|
|
83
|
-
pnpm run build
|
|
84
|
-
pnpm run test
|
|
85
|
-
```
|
|
86
|
-
|
|
87
|
-
## License
|
|
88
|
-
|
|
89
|
-
MIT
|
|
1
|
+
# @shotstack/schemas
|
|
2
|
+
|
|
3
|
+
Centralized OpenAPI schemas and TypeScript types for the Shotstack API
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @shotstack/schemas zod
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
### TypeScript Types
|
|
14
|
+
|
|
15
|
+
```typescript
|
|
16
|
+
import type { components } from '@shotstack/schemas';
|
|
17
|
+
|
|
18
|
+
type Edit = components['schemas']['Edit'];
|
|
19
|
+
type Timeline = components['schemas']['Timeline'];
|
|
20
|
+
type Clip = components['schemas']['Clip'];
|
|
21
|
+
type Output = components['schemas']['Output'];
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
### Zod Schemas
|
|
25
|
+
|
|
26
|
+
```typescript
|
|
27
|
+
import { z } from 'zod';
|
|
28
|
+
import { richTextAssetSchema, editSchema, timelineSchema } from '@shotstack/schemas/zod';
|
|
29
|
+
|
|
30
|
+
const result = richTextAssetSchema.safeParse(inputData);
|
|
31
|
+
if (result.success) {
|
|
32
|
+
console.log(result.data);
|
|
33
|
+
}
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
### Extending Schemas
|
|
37
|
+
|
|
38
|
+
```typescript
|
|
39
|
+
import { z } from 'zod';
|
|
40
|
+
import { richTextAssetSchema } from '@shotstack/schemas/zod';
|
|
41
|
+
|
|
42
|
+
const ExtendedAsset = richTextAssetSchema.extend({
|
|
43
|
+
customFonts: z.array(z.object({
|
|
44
|
+
src: z.string().url(),
|
|
45
|
+
family: z.string(),
|
|
46
|
+
})).optional(),
|
|
47
|
+
border: z.object({
|
|
48
|
+
width: z.number().min(0),
|
|
49
|
+
color: z.string(),
|
|
50
|
+
}).optional(),
|
|
51
|
+
});
|
|
52
|
+
|
|
53
|
+
type ExtendedAssetType = z.infer<typeof ExtendedAsset>;
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### Custom Validation
|
|
57
|
+
|
|
58
|
+
```typescript
|
|
59
|
+
import { richTextAnimationSchema } from '@shotstack/schemas/zod';
|
|
60
|
+
|
|
61
|
+
const AnimationWithDirection = richTextAnimationSchema.refine(
|
|
62
|
+
(data) => {
|
|
63
|
+
if (data.preset === 'slideIn' && !data.direction) {
|
|
64
|
+
return false;
|
|
65
|
+
}
|
|
66
|
+
return true;
|
|
67
|
+
},
|
|
68
|
+
{ message: 'direction is required for slideIn preset' }
|
|
69
|
+
);
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
## Available Schemas
|
|
73
|
+
|
|
74
|
+
- Edit, Timeline, Track, Clip, Output
|
|
75
|
+
- Assets: VideoAsset, ImageAsset, AudioAsset, HtmlAsset, TextAsset, TitleAsset, LumaAsset, CaptionAsset, ShapeAsset, RichTextAsset
|
|
76
|
+
- Destinations: ShotstackDestination, S3Destination, MuxDestination, VimeoDestination, GoogleDriveDestination, GoogleCloudStorageDestination
|
|
77
|
+
- Transforms, Transitions, Fonts, MergeFields, and more
|
|
78
|
+
|
|
79
|
+
## Development
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
pnpm install
|
|
83
|
+
pnpm run build
|
|
84
|
+
pnpm run test
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
## License
|
|
88
|
+
|
|
89
|
+
MIT
|
package/dist/api.bundled.json
CHANGED
|
@@ -1965,6 +1965,17 @@
|
|
|
1965
1965
|
"type": "string",
|
|
1966
1966
|
"pattern": "^#[A-Fa-f0-9]{6}$",
|
|
1967
1967
|
"example": "#000000"
|
|
1968
|
+
},
|
|
1969
|
+
"textDecoration": {
|
|
1970
|
+
"description": "Text decoration to apply to all words.",
|
|
1971
|
+
"type": "string",
|
|
1972
|
+
"enum": [
|
|
1973
|
+
"none",
|
|
1974
|
+
"underline",
|
|
1975
|
+
"line-through"
|
|
1976
|
+
],
|
|
1977
|
+
"default": "none",
|
|
1978
|
+
"example": "underline"
|
|
1968
1979
|
}
|
|
1969
1980
|
},
|
|
1970
1981
|
"additionalProperties": false,
|
|
@@ -2047,6 +2058,17 @@
|
|
|
2047
2058
|
"maximum": 1,
|
|
2048
2059
|
"default": 1,
|
|
2049
2060
|
"example": 1
|
|
2061
|
+
},
|
|
2062
|
+
"textDecoration": {
|
|
2063
|
+
"description": "Text decoration to apply to the active word.",
|
|
2064
|
+
"type": "string",
|
|
2065
|
+
"enum": [
|
|
2066
|
+
"none",
|
|
2067
|
+
"underline",
|
|
2068
|
+
"line-through"
|
|
2069
|
+
],
|
|
2070
|
+
"default": "none",
|
|
2071
|
+
"example": "underline"
|
|
2050
2072
|
}
|
|
2051
2073
|
},
|
|
2052
2074
|
"additionalProperties": false
|
|
@@ -2063,6 +2085,10 @@
|
|
|
2063
2085
|
"description": "Stroke properties for the active word.",
|
|
2064
2086
|
"$ref": "#/components/schemas/RichTextStroke"
|
|
2065
2087
|
},
|
|
2088
|
+
"shadow": {
|
|
2089
|
+
"description": "Shadow properties for the active word. Overrides the base shadow when a word is active.",
|
|
2090
|
+
"$ref": "#/components/schemas/RichTextShadow"
|
|
2091
|
+
},
|
|
2066
2092
|
"scale": {
|
|
2067
2093
|
"description": "Scale multiplier for the active word. 1.0 is normal size, 1.2 is 20% larger.",
|
|
2068
2094
|
"type": "number",
|
|
@@ -1570,6 +1570,21 @@
|
|
|
1570
1570
|
"type": "null"
|
|
1571
1571
|
}
|
|
1572
1572
|
]
|
|
1573
|
+
},
|
|
1574
|
+
"textDecoration": {
|
|
1575
|
+
"anyOf": [
|
|
1576
|
+
{
|
|
1577
|
+
"type": "string",
|
|
1578
|
+
"enum": [
|
|
1579
|
+
"none",
|
|
1580
|
+
"underline",
|
|
1581
|
+
"line-through"
|
|
1582
|
+
]
|
|
1583
|
+
},
|
|
1584
|
+
{
|
|
1585
|
+
"type": "null"
|
|
1586
|
+
}
|
|
1587
|
+
]
|
|
1573
1588
|
}
|
|
1574
1589
|
},
|
|
1575
1590
|
"additionalProperties": false,
|
|
@@ -1579,7 +1594,8 @@
|
|
|
1579
1594
|
"weight",
|
|
1580
1595
|
"color",
|
|
1581
1596
|
"opacity",
|
|
1582
|
-
"background"
|
|
1597
|
+
"background",
|
|
1598
|
+
"textDecoration"
|
|
1583
1599
|
]
|
|
1584
1600
|
},
|
|
1585
1601
|
{
|
|
@@ -1721,6 +1737,16 @@
|
|
|
1721
1737
|
}
|
|
1722
1738
|
]
|
|
1723
1739
|
},
|
|
1740
|
+
"shadow": {
|
|
1741
|
+
"anyOf": [
|
|
1742
|
+
{
|
|
1743
|
+
"$ref": "#/$defs/RichTextShadow"
|
|
1744
|
+
},
|
|
1745
|
+
{
|
|
1746
|
+
"type": "null"
|
|
1747
|
+
}
|
|
1748
|
+
]
|
|
1749
|
+
},
|
|
1724
1750
|
"scale": {
|
|
1725
1751
|
"anyOf": [
|
|
1726
1752
|
{
|
|
@@ -1738,6 +1764,7 @@
|
|
|
1738
1764
|
"required": [
|
|
1739
1765
|
"font",
|
|
1740
1766
|
"stroke",
|
|
1767
|
+
"shadow",
|
|
1741
1768
|
"scale"
|
|
1742
1769
|
]
|
|
1743
1770
|
},
|
|
@@ -1778,13 +1805,29 @@
|
|
|
1778
1805
|
"type": "null"
|
|
1779
1806
|
}
|
|
1780
1807
|
]
|
|
1808
|
+
},
|
|
1809
|
+
"textDecoration": {
|
|
1810
|
+
"anyOf": [
|
|
1811
|
+
{
|
|
1812
|
+
"type": "string",
|
|
1813
|
+
"enum": [
|
|
1814
|
+
"none",
|
|
1815
|
+
"underline",
|
|
1816
|
+
"line-through"
|
|
1817
|
+
]
|
|
1818
|
+
},
|
|
1819
|
+
{
|
|
1820
|
+
"type": "null"
|
|
1821
|
+
}
|
|
1822
|
+
]
|
|
1781
1823
|
}
|
|
1782
1824
|
},
|
|
1783
1825
|
"additionalProperties": false,
|
|
1784
1826
|
"required": [
|
|
1785
1827
|
"color",
|
|
1786
1828
|
"background",
|
|
1787
|
-
"opacity"
|
|
1829
|
+
"opacity",
|
|
1830
|
+
"textDecoration"
|
|
1788
1831
|
]
|
|
1789
1832
|
},
|
|
1790
1833
|
"RichCaptionWordAnimation": {
|
|
@@ -1802,6 +1802,21 @@
|
|
|
1802
1802
|
"type": "null"
|
|
1803
1803
|
}
|
|
1804
1804
|
]
|
|
1805
|
+
},
|
|
1806
|
+
"textDecoration": {
|
|
1807
|
+
"anyOf": [
|
|
1808
|
+
{
|
|
1809
|
+
"type": "string",
|
|
1810
|
+
"enum": [
|
|
1811
|
+
"none",
|
|
1812
|
+
"underline",
|
|
1813
|
+
"line-through"
|
|
1814
|
+
]
|
|
1815
|
+
},
|
|
1816
|
+
{
|
|
1817
|
+
"type": "null"
|
|
1818
|
+
}
|
|
1819
|
+
]
|
|
1805
1820
|
}
|
|
1806
1821
|
},
|
|
1807
1822
|
"additionalProperties": false,
|
|
@@ -1811,7 +1826,8 @@
|
|
|
1811
1826
|
"weight",
|
|
1812
1827
|
"color",
|
|
1813
1828
|
"opacity",
|
|
1814
|
-
"background"
|
|
1829
|
+
"background",
|
|
1830
|
+
"textDecoration"
|
|
1815
1831
|
]
|
|
1816
1832
|
},
|
|
1817
1833
|
{
|
|
@@ -1953,6 +1969,16 @@
|
|
|
1953
1969
|
}
|
|
1954
1970
|
]
|
|
1955
1971
|
},
|
|
1972
|
+
"shadow": {
|
|
1973
|
+
"anyOf": [
|
|
1974
|
+
{
|
|
1975
|
+
"$ref": "#/$defs/RichTextShadow"
|
|
1976
|
+
},
|
|
1977
|
+
{
|
|
1978
|
+
"type": "null"
|
|
1979
|
+
}
|
|
1980
|
+
]
|
|
1981
|
+
},
|
|
1956
1982
|
"scale": {
|
|
1957
1983
|
"anyOf": [
|
|
1958
1984
|
{
|
|
@@ -1970,6 +1996,7 @@
|
|
|
1970
1996
|
"required": [
|
|
1971
1997
|
"font",
|
|
1972
1998
|
"stroke",
|
|
1999
|
+
"shadow",
|
|
1973
2000
|
"scale"
|
|
1974
2001
|
]
|
|
1975
2002
|
},
|
|
@@ -2010,13 +2037,29 @@
|
|
|
2010
2037
|
"type": "null"
|
|
2011
2038
|
}
|
|
2012
2039
|
]
|
|
2040
|
+
},
|
|
2041
|
+
"textDecoration": {
|
|
2042
|
+
"anyOf": [
|
|
2043
|
+
{
|
|
2044
|
+
"type": "string",
|
|
2045
|
+
"enum": [
|
|
2046
|
+
"none",
|
|
2047
|
+
"underline",
|
|
2048
|
+
"line-through"
|
|
2049
|
+
]
|
|
2050
|
+
},
|
|
2051
|
+
{
|
|
2052
|
+
"type": "null"
|
|
2053
|
+
}
|
|
2054
|
+
]
|
|
2013
2055
|
}
|
|
2014
2056
|
},
|
|
2015
2057
|
"additionalProperties": false,
|
|
2016
2058
|
"required": [
|
|
2017
2059
|
"color",
|
|
2018
2060
|
"background",
|
|
2019
|
-
"opacity"
|
|
2061
|
+
"opacity",
|
|
2062
|
+
"textDecoration"
|
|
2020
2063
|
]
|
|
2021
2064
|
},
|
|
2022
2065
|
"RichCaptionWordAnimation": {
|
|
@@ -1986,6 +1986,21 @@
|
|
|
1986
1986
|
"type": "null"
|
|
1987
1987
|
}
|
|
1988
1988
|
]
|
|
1989
|
+
},
|
|
1990
|
+
"textDecoration": {
|
|
1991
|
+
"anyOf": [
|
|
1992
|
+
{
|
|
1993
|
+
"type": "string",
|
|
1994
|
+
"enum": [
|
|
1995
|
+
"none",
|
|
1996
|
+
"underline",
|
|
1997
|
+
"line-through"
|
|
1998
|
+
]
|
|
1999
|
+
},
|
|
2000
|
+
{
|
|
2001
|
+
"type": "null"
|
|
2002
|
+
}
|
|
2003
|
+
]
|
|
1989
2004
|
}
|
|
1990
2005
|
},
|
|
1991
2006
|
"additionalProperties": false,
|
|
@@ -1995,7 +2010,8 @@
|
|
|
1995
2010
|
"weight",
|
|
1996
2011
|
"color",
|
|
1997
2012
|
"opacity",
|
|
1998
|
-
"background"
|
|
2013
|
+
"background",
|
|
2014
|
+
"textDecoration"
|
|
1999
2015
|
]
|
|
2000
2016
|
},
|
|
2001
2017
|
{
|
|
@@ -2137,6 +2153,16 @@
|
|
|
2137
2153
|
}
|
|
2138
2154
|
]
|
|
2139
2155
|
},
|
|
2156
|
+
"shadow": {
|
|
2157
|
+
"anyOf": [
|
|
2158
|
+
{
|
|
2159
|
+
"$ref": "#/$defs/RichTextShadow"
|
|
2160
|
+
},
|
|
2161
|
+
{
|
|
2162
|
+
"type": "null"
|
|
2163
|
+
}
|
|
2164
|
+
]
|
|
2165
|
+
},
|
|
2140
2166
|
"scale": {
|
|
2141
2167
|
"anyOf": [
|
|
2142
2168
|
{
|
|
@@ -2154,6 +2180,7 @@
|
|
|
2154
2180
|
"required": [
|
|
2155
2181
|
"font",
|
|
2156
2182
|
"stroke",
|
|
2183
|
+
"shadow",
|
|
2157
2184
|
"scale"
|
|
2158
2185
|
]
|
|
2159
2186
|
},
|
|
@@ -2194,13 +2221,29 @@
|
|
|
2194
2221
|
"type": "null"
|
|
2195
2222
|
}
|
|
2196
2223
|
]
|
|
2224
|
+
},
|
|
2225
|
+
"textDecoration": {
|
|
2226
|
+
"anyOf": [
|
|
2227
|
+
{
|
|
2228
|
+
"type": "string",
|
|
2229
|
+
"enum": [
|
|
2230
|
+
"none",
|
|
2231
|
+
"underline",
|
|
2232
|
+
"line-through"
|
|
2233
|
+
]
|
|
2234
|
+
},
|
|
2235
|
+
{
|
|
2236
|
+
"type": "null"
|
|
2237
|
+
}
|
|
2238
|
+
]
|
|
2197
2239
|
}
|
|
2198
2240
|
},
|
|
2199
2241
|
"additionalProperties": false,
|
|
2200
2242
|
"required": [
|
|
2201
2243
|
"color",
|
|
2202
2244
|
"background",
|
|
2203
|
-
"opacity"
|
|
2245
|
+
"opacity",
|
|
2246
|
+
"textDecoration"
|
|
2204
2247
|
]
|
|
2205
2248
|
},
|
|
2206
2249
|
"RichCaptionWordAnimation": {
|
|
@@ -42,13 +42,30 @@
|
|
|
42
42
|
"type": "null"
|
|
43
43
|
}
|
|
44
44
|
]
|
|
45
|
+
},
|
|
46
|
+
"textDecoration": {
|
|
47
|
+
"anyOf": [
|
|
48
|
+
{
|
|
49
|
+
"type": "string",
|
|
50
|
+
"description": "Text decoration to apply to the active word.",
|
|
51
|
+
"enum": [
|
|
52
|
+
"none",
|
|
53
|
+
"underline",
|
|
54
|
+
"line-through"
|
|
55
|
+
]
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"type": "null"
|
|
59
|
+
}
|
|
60
|
+
]
|
|
45
61
|
}
|
|
46
62
|
},
|
|
47
63
|
"additionalProperties": false,
|
|
48
64
|
"required": [
|
|
49
65
|
"color",
|
|
50
66
|
"background",
|
|
51
|
-
"opacity"
|
|
67
|
+
"opacity",
|
|
68
|
+
"textDecoration"
|
|
52
69
|
]
|
|
53
70
|
}
|
|
54
71
|
}
|
|
@@ -27,6 +27,17 @@
|
|
|
27
27
|
}
|
|
28
28
|
]
|
|
29
29
|
},
|
|
30
|
+
"shadow": {
|
|
31
|
+
"anyOf": [
|
|
32
|
+
{
|
|
33
|
+
"description": "Shadow properties for the active word. Overrides the base shadow when a word is active.",
|
|
34
|
+
"$ref": "#/$defs/RichTextShadow"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"type": "null"
|
|
38
|
+
}
|
|
39
|
+
]
|
|
40
|
+
},
|
|
30
41
|
"scale": {
|
|
31
42
|
"anyOf": [
|
|
32
43
|
{
|
|
@@ -45,6 +56,7 @@
|
|
|
45
56
|
"required": [
|
|
46
57
|
"font",
|
|
47
58
|
"stroke",
|
|
59
|
+
"shadow",
|
|
48
60
|
"scale"
|
|
49
61
|
],
|
|
50
62
|
"$defs": {
|
|
@@ -89,13 +101,30 @@
|
|
|
89
101
|
"type": "null"
|
|
90
102
|
}
|
|
91
103
|
]
|
|
104
|
+
},
|
|
105
|
+
"textDecoration": {
|
|
106
|
+
"anyOf": [
|
|
107
|
+
{
|
|
108
|
+
"type": "string",
|
|
109
|
+
"description": "Text decoration to apply to the active word.",
|
|
110
|
+
"enum": [
|
|
111
|
+
"none",
|
|
112
|
+
"underline",
|
|
113
|
+
"line-through"
|
|
114
|
+
]
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
"type": "null"
|
|
118
|
+
}
|
|
119
|
+
]
|
|
92
120
|
}
|
|
93
121
|
},
|
|
94
122
|
"additionalProperties": false,
|
|
95
123
|
"required": [
|
|
96
124
|
"color",
|
|
97
125
|
"background",
|
|
98
|
-
"opacity"
|
|
126
|
+
"opacity",
|
|
127
|
+
"textDecoration"
|
|
99
128
|
]
|
|
100
129
|
},
|
|
101
130
|
"RichTextStroke": {
|
|
@@ -148,6 +177,81 @@
|
|
|
148
177
|
"color",
|
|
149
178
|
"opacity"
|
|
150
179
|
]
|
|
180
|
+
},
|
|
181
|
+
"RichTextShadow": {
|
|
182
|
+
"description": "Text shadow properties.",
|
|
183
|
+
"properties": {
|
|
184
|
+
"offsetX": {
|
|
185
|
+
"anyOf": [
|
|
186
|
+
{
|
|
187
|
+
"type": "number",
|
|
188
|
+
"description": "Horizontal offset of the shadow in pixels. Positive values move right, negative left."
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
"type": "null"
|
|
192
|
+
}
|
|
193
|
+
]
|
|
194
|
+
},
|
|
195
|
+
"offsetY": {
|
|
196
|
+
"anyOf": [
|
|
197
|
+
{
|
|
198
|
+
"type": "number",
|
|
199
|
+
"description": "Vertical offset of the shadow in pixels. Positive values move down, negative up."
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
"type": "null"
|
|
203
|
+
}
|
|
204
|
+
]
|
|
205
|
+
},
|
|
206
|
+
"blur": {
|
|
207
|
+
"anyOf": [
|
|
208
|
+
{
|
|
209
|
+
"type": "number",
|
|
210
|
+
"description": "The blur radius of the shadow in pixels. Must be 0 or greater.",
|
|
211
|
+
"minimum": 0
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"type": "null"
|
|
215
|
+
}
|
|
216
|
+
]
|
|
217
|
+
},
|
|
218
|
+
"color": {
|
|
219
|
+
"anyOf": [
|
|
220
|
+
{
|
|
221
|
+
"type": "string",
|
|
222
|
+
"description": "The shadow color using hexadecimal color notation.",
|
|
223
|
+
"enum": [
|
|
224
|
+
"#000000"
|
|
225
|
+
]
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
"type": "null"
|
|
229
|
+
}
|
|
230
|
+
]
|
|
231
|
+
},
|
|
232
|
+
"opacity": {
|
|
233
|
+
"anyOf": [
|
|
234
|
+
{
|
|
235
|
+
"type": "number",
|
|
236
|
+
"description": "The opacity of the shadow where 1 is opaque and 0 is transparent.",
|
|
237
|
+
"minimum": 0,
|
|
238
|
+
"maximum": 1
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
"type": "null"
|
|
242
|
+
}
|
|
243
|
+
]
|
|
244
|
+
}
|
|
245
|
+
},
|
|
246
|
+
"additionalProperties": false,
|
|
247
|
+
"type": "object",
|
|
248
|
+
"required": [
|
|
249
|
+
"offsetX",
|
|
250
|
+
"offsetY",
|
|
251
|
+
"blur",
|
|
252
|
+
"color",
|
|
253
|
+
"opacity"
|
|
254
|
+
]
|
|
151
255
|
}
|
|
152
256
|
}
|
|
153
257
|
}
|