@player-ui/reference-assets-plugin-react 0.8.0--canary.307.9621 → 0.8.0-next.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.
Files changed (76) hide show
  1. package/dist/cjs/index.cjs +581 -0
  2. package/dist/cjs/index.cjs.map +1 -0
  3. package/dist/index.css +703 -0
  4. package/dist/index.legacy-esm.js +529 -0
  5. package/dist/index.mjs +529 -0
  6. package/dist/index.mjs.map +1 -0
  7. package/package.json +34 -63
  8. package/src/__tests__/integration.test.tsx +158 -0
  9. package/src/assets/action/Action.tsx +10 -14
  10. package/src/assets/action/hooks.tsx +6 -6
  11. package/src/assets/action/index.ts +2 -2
  12. package/src/assets/choice/Choice.tsx +52 -0
  13. package/src/assets/choice/hooks.tsx +34 -0
  14. package/src/assets/choice/index.ts +2 -0
  15. package/src/assets/collection/Collection.tsx +6 -9
  16. package/src/assets/collection/index.tsx +1 -1
  17. package/src/assets/image/Image.tsx +4 -4
  18. package/src/assets/image/index.tsx +1 -1
  19. package/src/assets/index.tsx +7 -6
  20. package/src/assets/info/Info.tsx +26 -29
  21. package/src/assets/info/index.tsx +1 -1
  22. package/src/assets/input/Input.tsx +27 -19
  23. package/src/assets/input/hooks.tsx +35 -35
  24. package/src/assets/input/index.tsx +2 -2
  25. package/src/assets/input/types.ts +2 -2
  26. package/src/assets/text/Text.tsx +13 -7
  27. package/src/assets/text/hooks.tsx +6 -6
  28. package/src/assets/text/index.tsx +2 -2
  29. package/src/components/Button.tsx +56 -0
  30. package/src/components/ChoiceItem.tsx +31 -0
  31. package/src/components/Input.tsx +26 -0
  32. package/src/components/Label.tsx +26 -0
  33. package/src/components/Separator.tsx +30 -0
  34. package/src/global.css +83 -0
  35. package/src/index.tsx +4 -2
  36. package/src/intro.stories.mdx +9 -9
  37. package/src/plugin.tsx +22 -43
  38. package/src/utils.ts +6 -0
  39. package/types/assets/action/Action.d.ts +7 -0
  40. package/types/assets/action/hooks.d.ts +9 -0
  41. package/types/assets/action/index.d.ts +3 -0
  42. package/types/assets/choice/Choice.d.ts +6 -0
  43. package/types/assets/choice/hooks.d.ts +5 -0
  44. package/types/assets/choice/index.d.ts +3 -0
  45. package/types/assets/collection/Collection.d.ts +4 -0
  46. package/types/assets/collection/index.d.ts +2 -0
  47. package/types/assets/image/Image.d.ts +4 -0
  48. package/types/assets/image/index.d.ts +2 -0
  49. package/types/assets/index.d.ts +8 -0
  50. package/types/assets/info/Info.d.ts +5 -0
  51. package/types/assets/info/index.d.ts +2 -0
  52. package/types/assets/input/Input.d.ts +6 -0
  53. package/types/assets/input/hooks.d.ts +40 -0
  54. package/types/assets/input/index.d.ts +3 -0
  55. package/types/assets/input/types.d.ts +3 -0
  56. package/types/assets/text/Text.d.ts +7 -0
  57. package/types/assets/text/hooks.d.ts +9 -0
  58. package/types/assets/text/index.d.ts +3 -0
  59. package/types/components/Button.d.ts +12 -0
  60. package/types/components/ChoiceItem.d.ts +7 -0
  61. package/types/components/Input.d.ts +6 -0
  62. package/types/components/Label.d.ts +6 -0
  63. package/types/components/Separator.d.ts +5 -0
  64. package/types/index.d.ts +4 -0
  65. package/types/plugin.d.ts +19 -0
  66. package/types/utils.d.ts +3 -0
  67. package/dist/index.cjs.js +0 -501
  68. package/dist/index.d.ts +0 -94
  69. package/dist/index.esm.js +0 -479
  70. package/dist/xlr/ActionAsset.json +0 -126
  71. package/dist/xlr/CollectionAsset.json +0 -40
  72. package/dist/xlr/InfoAsset.json +0 -58
  73. package/dist/xlr/InputAsset.json +0 -109
  74. package/dist/xlr/TextAsset.json +0 -125
  75. package/dist/xlr/manifest.js +0 -16
  76. package/dist/xlr/manifest.json +0 -22
@@ -1,58 +0,0 @@
1
- {
2
- "source": "/home/circleci/.cache/bazel/_bazel_circleci/e8362d362e14c7d23506d1dfa3aea8b8/sandbox/processwrapper-sandbox/3566/execroot/player/node_modules/@player-ui/reference-assets-plugin/dist/index.d.ts",
3
- "name": "InfoAsset",
4
- "type": "object",
5
- "properties": {
6
- "title": {
7
- "required": false,
8
- "node": {
9
- "type": "ref",
10
- "ref": "AssetWrapper",
11
- "title": "InfoAsset.title",
12
- "description": "The string value to show"
13
- }
14
- },
15
- "subTitle": {
16
- "required": false,
17
- "node": {
18
- "type": "ref",
19
- "ref": "AssetWrapper",
20
- "title": "InfoAsset.subTitle",
21
- "description": "subtitle"
22
- }
23
- },
24
- "primaryInfo": {
25
- "required": false,
26
- "node": {
27
- "type": "ref",
28
- "ref": "AssetWrapper",
29
- "title": "InfoAsset.primaryInfo",
30
- "description": "Primary place for info"
31
- }
32
- },
33
- "actions": {
34
- "required": false,
35
- "node": {
36
- "type": "array",
37
- "elementType": {
38
- "type": "ref",
39
- "ref": "AssetWrapper"
40
- },
41
- "title": "InfoAsset.actions",
42
- "description": "List of actions to show at the bottom of the page"
43
- }
44
- }
45
- },
46
- "additionalProperties": false,
47
- "title": "InfoAsset",
48
- "extends": {
49
- "type": "ref",
50
- "ref": "Asset<'info'>",
51
- "genericArguments": [
52
- {
53
- "type": "string",
54
- "const": "info"
55
- }
56
- ]
57
- }
58
- }
@@ -1,109 +0,0 @@
1
- {
2
- "source": "/home/circleci/.cache/bazel/_bazel_circleci/e8362d362e14c7d23506d1dfa3aea8b8/sandbox/processwrapper-sandbox/3566/execroot/player/node_modules/@player-ui/reference-assets-plugin/dist/index.d.ts",
3
- "name": "InputAsset",
4
- "type": "object",
5
- "properties": {
6
- "label": {
7
- "required": false,
8
- "node": {
9
- "type": "ref",
10
- "ref": "AssetWrapper<AnyTextAsset>",
11
- "genericArguments": [
12
- {
13
- "type": "ref",
14
- "ref": "AnyTextAsset"
15
- }
16
- ],
17
- "title": "InputAsset.label",
18
- "description": "Asset container for a field label."
19
- }
20
- },
21
- "note": {
22
- "required": false,
23
- "node": {
24
- "type": "ref",
25
- "ref": "AssetWrapper<AnyTextAsset>",
26
- "genericArguments": [
27
- {
28
- "type": "ref",
29
- "ref": "AnyTextAsset"
30
- }
31
- ],
32
- "title": "InputAsset.note",
33
- "description": "Asset container for a note."
34
- }
35
- },
36
- "binding": {
37
- "required": true,
38
- "node": {
39
- "type": "ref",
40
- "ref": "Binding",
41
- "title": "InputAsset.binding",
42
- "description": "The location in the data-model to store the data"
43
- }
44
- },
45
- "metaData": {
46
- "required": false,
47
- "node": {
48
- "type": "object",
49
- "properties": {
50
- "beacon": {
51
- "required": false,
52
- "node": {
53
- "source": "/home/circleci/.cache/bazel/_bazel_circleci/e8362d362e14c7d23506d1dfa3aea8b8/sandbox/processwrapper-sandbox/3566/execroot/player/node_modules/@player-ui/beacon-plugin/dist/index.d.ts",
54
- "name": "BeaconDataType",
55
- "type": "or",
56
- "or": [
57
- {
58
- "type": "string",
59
- "title": "BeaconDataType"
60
- },
61
- {
62
- "type": "record",
63
- "keyType": {
64
- "type": "string"
65
- },
66
- "valueType": {
67
- "type": "any"
68
- },
69
- "title": "BeaconDataType"
70
- }
71
- ],
72
- "title": "InputAsset.metaData.beacon",
73
- "description": "Additional data to beacon when this input changes"
74
- }
75
- }
76
- },
77
- "additionalProperties": false,
78
- "title": "InputAsset.metaData",
79
- "description": "Optional additional data"
80
- }
81
- }
82
- },
83
- "additionalProperties": false,
84
- "title": "InputAsset",
85
- "description": "This is the most generic way of gathering data. The input is bound to a data model using the 'binding' property.\nPlayers can get field type information from the 'schema' definition, thus to decide the input controls for visual rendering.",
86
- "genericTokens": [
87
- {
88
- "symbol": "AnyTextAsset",
89
- "constraints": {
90
- "type": "ref",
91
- "ref": "Asset"
92
- },
93
- "default": {
94
- "type": "ref",
95
- "ref": "Asset"
96
- }
97
- }
98
- ],
99
- "extends": {
100
- "type": "ref",
101
- "ref": "Asset<'input'>",
102
- "genericArguments": [
103
- {
104
- "type": "string",
105
- "const": "input"
106
- }
107
- ]
108
- }
109
- }
@@ -1,125 +0,0 @@
1
- {
2
- "source": "/home/circleci/.cache/bazel/_bazel_circleci/e8362d362e14c7d23506d1dfa3aea8b8/sandbox/processwrapper-sandbox/3566/execroot/player/node_modules/@player-ui/reference-assets-plugin/dist/index.d.ts",
3
- "name": "TextAsset",
4
- "type": "object",
5
- "properties": {
6
- "value": {
7
- "required": true,
8
- "node": {
9
- "type": "string",
10
- "title": "TextAsset.value",
11
- "description": "The text to display"
12
- }
13
- },
14
- "modifiers": {
15
- "required": false,
16
- "node": {
17
- "type": "array",
18
- "elementType": {
19
- "source": "/home/circleci/.cache/bazel/_bazel_circleci/e8362d362e14c7d23506d1dfa3aea8b8/sandbox/processwrapper-sandbox/3566/execroot/player/node_modules/@player-ui/reference-assets-plugin/dist/index.d.ts",
20
- "name": "TextModifier",
21
- "type": "or",
22
- "or": [
23
- {
24
- "source": "/home/circleci/.cache/bazel/_bazel_circleci/e8362d362e14c7d23506d1dfa3aea8b8/sandbox/processwrapper-sandbox/3566/execroot/player/node_modules/@player-ui/reference-assets-plugin/dist/index.d.ts",
25
- "name": "BasicTextModifier",
26
- "type": "object",
27
- "properties": {
28
- "type": {
29
- "required": true,
30
- "node": {
31
- "type": "string",
32
- "title": "BasicTextModifier.type",
33
- "description": "The modifier type"
34
- }
35
- },
36
- "name": {
37
- "required": false,
38
- "node": {
39
- "type": "string",
40
- "title": "BasicTextModifier.name",
41
- "description": "Modifiers can be named when used in strings"
42
- }
43
- }
44
- },
45
- "additionalProperties": {
46
- "type": "unknown"
47
- },
48
- "title": "BasicTextModifier"
49
- },
50
- {
51
- "source": "/home/circleci/.cache/bazel/_bazel_circleci/e8362d362e14c7d23506d1dfa3aea8b8/sandbox/processwrapper-sandbox/3566/execroot/player/node_modules/@player-ui/reference-assets-plugin/dist/index.d.ts",
52
- "name": "LinkModifier",
53
- "type": "object",
54
- "properties": {
55
- "type": {
56
- "required": true,
57
- "node": {
58
- "type": "string",
59
- "const": "link",
60
- "title": "LinkModifier.type",
61
- "description": "The link type denotes this as a link"
62
- }
63
- },
64
- "exp": {
65
- "required": false,
66
- "node": {
67
- "type": "ref",
68
- "ref": "Expression",
69
- "title": "LinkModifier.exp",
70
- "description": "An optional expression to run before the link is opened"
71
- }
72
- },
73
- "metaData": {
74
- "required": true,
75
- "node": {
76
- "type": "object",
77
- "properties": {
78
- "ref": {
79
- "required": true,
80
- "node": {
81
- "type": "string",
82
- "title": "LinkModifier.metaData.ref",
83
- "description": "The location of the link to load"
84
- }
85
- },
86
- "'mime-type'": {
87
- "required": false,
88
- "node": {
89
- "type": "string",
90
- "title": "LinkModifier.metaData.'mime-type'",
91
- "description": "Used to indicate an application specific resolver to use"
92
- }
93
- }
94
- },
95
- "additionalProperties": false,
96
- "title": "LinkModifier.metaData",
97
- "description": "metaData about the link's target"
98
- }
99
- }
100
- },
101
- "additionalProperties": false,
102
- "title": "LinkModifier",
103
- "description": "A modifier to turn the text into a link"
104
- }
105
- ],
106
- "title": "TextModifier"
107
- },
108
- "title": "TextAsset.modifiers",
109
- "description": "Any modifiers on the text"
110
- }
111
- }
112
- },
113
- "additionalProperties": false,
114
- "title": "TextAsset",
115
- "extends": {
116
- "type": "ref",
117
- "ref": "Asset<'text'>",
118
- "genericArguments": [
119
- {
120
- "type": "string",
121
- "const": "text"
122
- }
123
- ]
124
- }
125
- }
@@ -1,16 +0,0 @@
1
- const InputAsset = require('./InputAsset.json')
2
- const TextAsset = require('./TextAsset.json')
3
- const ActionAsset = require('./ActionAsset.json')
4
- const CollectionAsset = require('./CollectionAsset.json')
5
- const InfoAsset = require('./InfoAsset.json')
6
-
7
- module.exports = {
8
- "pluginName": "reference-assets-web-plugin",
9
- "capabilities": {
10
- "Assets":[InputAsset,TextAsset,ActionAsset,CollectionAsset],
11
- "Views":[InfoAsset],
12
- },
13
- "customPrimitives": [
14
- 'Expression','Asset','Binding','AssetWrapper','Schema.DataType','ExpressionHandler'
15
- ]
16
- }
@@ -1,22 +0,0 @@
1
- {
2
- "pluginName": "reference-assets-web-plugin",
3
- "capabilities": {
4
- "Assets": [
5
- "InputAsset",
6
- "TextAsset",
7
- "ActionAsset",
8
- "CollectionAsset"
9
- ],
10
- "Views": [
11
- "InfoAsset"
12
- ]
13
- },
14
- "customPrimitives": [
15
- "Expression",
16
- "Asset",
17
- "Binding",
18
- "AssetWrapper",
19
- "Schema.DataType",
20
- "ExpressionHandler"
21
- ]
22
- }