@devvit/ui-renderer 0.9.4 → 0.9.5

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 (61) hide show
  1. package/blocks/attributes.d.ts.map +1 -1
  2. package/blocks/components/devvit-blocks-renderer.d.ts +15 -0
  3. package/blocks/components/devvit-blocks-renderer.d.ts.map +1 -0
  4. package/blocks/components/devvit-blocks-renderer.js +42 -0
  5. package/blocks/components/devvit-blocks-webview.d.ts.map +1 -1
  6. package/blocks/index.d.ts.map +1 -1
  7. package/blocks/templates/index.d.ts.map +1 -1
  8. package/blocks/templates/renderAnimationBlock.d.ts +1 -0
  9. package/blocks/templates/renderAnimationBlock.d.ts.map +1 -1
  10. package/blocks/templates/renderAnimationBlock.js +1 -0
  11. package/blocks/templates/renderAvatarBlock.d.ts.map +1 -1
  12. package/blocks/templates/renderBlock.d.ts.map +1 -1
  13. package/blocks/templates/renderButtonBlock.d.ts.map +1 -1
  14. package/blocks/templates/renderButtonBlock.js +5 -3
  15. package/blocks/templates/renderContext.d.ts.map +1 -1
  16. package/blocks/templates/renderFullSnooBlock.d.ts.map +1 -1
  17. package/blocks/templates/renderIconBlock.d.ts.map +1 -1
  18. package/blocks/templates/renderIconBlock.js +14 -5
  19. package/blocks/templates/renderImageBlock.d.ts.map +1 -1
  20. package/blocks/templates/renderSpacerBlock.d.ts.map +1 -1
  21. package/blocks/templates/renderStackBlock.d.ts.map +1 -1
  22. package/blocks/templates/renderTextBlock.d.ts.map +1 -1
  23. package/blocks/templates/renderWebViewBlock.d.ts.map +1 -1
  24. package/blocks/templates/util.d.ts +3 -0
  25. package/blocks/templates/util.d.ts.map +1 -1
  26. package/blocks/templates/util.js +27 -8
  27. package/client/blocks.d.ts.map +1 -1
  28. package/client/devvit-animation-player.d.ts.map +1 -1
  29. package/client/devvit-custom-post.d.ts +7 -2
  30. package/client/devvit-custom-post.d.ts.map +1 -1
  31. package/client/devvit-custom-post.js +18 -29
  32. package/client/effects/devvit-effect-handler.d.ts.map +1 -1
  33. package/client/effects/form-effect-handler.d.ts.map +1 -1
  34. package/client/effects/toast-effect-handler.d.ts.map +1 -1
  35. package/client/formbuilder/components/devvit-form-selection-dropdown.d.ts.map +1 -1
  36. package/client/formbuilder/components/devvit-form-selection-dropdown.js +11 -1
  37. package/client/formbuilder/components/devvit-form-selection-list.d.ts.map +1 -1
  38. package/client/formbuilder/devvit-form-dialog.d.ts.map +1 -1
  39. package/client/formbuilder/fields/index.d.ts.map +1 -1
  40. package/client/formbuilder/fields/renderBooleanField.d.ts.map +1 -1
  41. package/client/formbuilder/fields/renderFieldLabel.d.ts.map +1 -1
  42. package/client/formbuilder/fields/renderFormFields.d.ts.map +1 -1
  43. package/client/formbuilder/fields/renderGroupField.d.ts.map +1 -1
  44. package/client/formbuilder/fields/renderHelpText.d.ts.map +1 -1
  45. package/client/formbuilder/fields/renderListField.d.ts.map +1 -1
  46. package/client/formbuilder/fields/renderNumberField.d.ts.map +1 -1
  47. package/client/formbuilder/fields/renderParagraphField.d.ts.map +1 -1
  48. package/client/formbuilder/fields/renderSelectionField.d.ts.map +1 -1
  49. package/client/formbuilder/fields/renderStringField.d.ts.map +1 -1
  50. package/client/formbuilder/index.d.ts.map +1 -1
  51. package/custom-styles.css +36 -0
  52. package/index.d.ts.map +1 -1
  53. package/package.json +41 -22
  54. package/server/blocks.d.ts.map +1 -1
  55. package/styles.d.ts.map +1 -1
  56. package/styles.js +1 -1
  57. package/types/events.d.ts.map +1 -1
  58. package/client/assets/snooBlocks.d.ts +0 -2
  59. package/client/assets/snooBlocks.d.ts.map +0 -1
  60. package/client/assets/snooBlocks.js +0 -2
  61. package/styles.css +0 -804
@@ -0,0 +1,36 @@
1
+ /** Text outline classes */
2
+ .text-outline-thin-bright {
3
+ text-shadow: #000 1px 0 0.5px, #000 -1px 0 0.5px, #000 0 1px 0.5px, #000 0 -1px 0.5px;
4
+ }
5
+ .text-outline-thick-bright {
6
+ text-shadow: #000 1px 0 2px, #000 -1px 0 2px, #000 0 1px 1px, #000 0 -1px 1px, #000 1px 0 2px,
7
+ #000 -1px 0 2px, #000 0 1px 1px, #000 0 -1px 1px;
8
+ }
9
+ .text-outline-thin-dark {
10
+ text-shadow: #fff 1px 0 0.5px, #fff -1px 0 0.5px, #fff 0 1px 0.5px, #fff 0 -1px 0.5px;
11
+ }
12
+ .text-outline-thick-dark {
13
+ text-shadow: #fff 1px 0 2px, #fff -1px 0 2px, #fff 0 1px 1px, #fff 0 -1px 1px, #fff 1px 0 2px,
14
+ #fff -1px 0 2px, #fff 0 1px 1px, #fff 0 -1px 1px;
15
+ }
16
+ /** Custom border sizes */
17
+ .border-dx-thick {
18
+ border-width: 2px;
19
+ }
20
+ .border-dx-thin {
21
+ border-width: 1px;
22
+ }
23
+ /** Custom border radius sizes */
24
+ .rounded-dx-lg {
25
+ border-radius: 1.5rem;
26
+ }
27
+ .rounded-dx-md {
28
+ border-radius: 1rem;
29
+ }
30
+ .rounded-dx-sm {
31
+ border-radius: 0.5rem;
32
+ }
33
+ /** Custom z-index for form dialogs */
34
+ .z-dialog {
35
+ z-index: 100;
36
+ }
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../library/src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devvit/ui-renderer",
3
- "version": "0.9.4",
3
+ "version": "0.9.5",
4
4
  "license": "BSD-3-Clause",
5
5
  "repository": {
6
6
  "type": "git",
@@ -9,29 +9,46 @@
9
9
  "type": "module",
10
10
  "main": "./index.js",
11
11
  "scripts": {
12
- "build": "yarn build:typescript && yarn build:styles",
13
- "build:styles": "postcss -c postcss.config.cjs styles.css -o dist/styles.css && yarn build:styles-dist",
14
- "build:styles-dist": "node scripts/make-styles.js",
15
- "build:typescript": "tsc",
12
+ "build": "yarn library:build",
16
13
  "clean": "rm -rf .turbo coverage dist",
17
14
  "clobber": "yarn clean && rm -rf node_modules",
18
- "dev": "concurrently -n 'styles,styles-dist,typescript' 'yarn watch:styles' 'yarn watch:styles-dist' 'yarn watch:typescript'",
19
- "lint": "redlint . && yarn lint:circular-deps",
15
+ "dev": "yarn library:dev",
16
+ "library:build": "yarn library:build:typescript && yarn library:build:styles",
17
+ "library:build:custom-styles": "cd library && postcss custom-styles.css -o ../dist/custom-styles.css",
18
+ "library:build:styles": "cd library && postcss styles.css -o tailwind-build.css && yarn library:build:styles-dist && yarn library:build:custom-styles",
19
+ "library:build:styles-dist": "node scripts/make-styles.js",
20
+ "library:build:typescript": "tsc -p library",
21
+ "library:dev": "concurrently -n 'lib:styles,lib:styles-dist,lib:typescript' 'yarn library:dev:styles' 'yarn library:dev:styles-dist' 'yarn library:dev:typescript",
22
+ "library:dev:styles": "yarn library:build:styles -w",
23
+ "library:dev:styles-dist": "yarn library:build:styles-dist --watch",
24
+ "library:dev:typescript": "yarn library:build:typescript -w",
25
+ "library:lint": "redlint ./library",
26
+ "library:lint:fix": "yarn lint --fix",
27
+ "library:test": "yarn library:test:unit && yarn library:test:types && yarn library:lint",
28
+ "library:test:types": "tsc --noEmit -p library",
29
+ "library:test:unit": "vitest run -r library -c vitest.config.js",
30
+ "library:test:unit-with-coverage": "yarn library:test:unit --coverage",
31
+ "lint": "yarn library:lint && yarn lint:circular-deps",
20
32
  "lint:circular-deps": "yarn madge --circular dist/**/*.js",
21
- "lint:fix": "yarn lint --fix",
22
33
  "prepublishOnly": "publish-package-json",
23
- "test": "yarn test:unit && yarn test:types && yarn lint",
24
- "test:types": "tsc --noEmit",
25
- "test:unit": "vitest run",
26
- "test:unit-with-coverage": "vitest run --coverage",
27
- "watch:styles": "postcss -w -c postcss.config.cjs styles.css -o dist/styles.css",
28
- "watch:styles-dist": "node scripts/make-styles.js --watch",
29
- "watch:typescript": "tsc -w"
34
+ "test": "yarn library:test && yarn visual-test:test",
35
+ "test:types": "yarn library:test:types",
36
+ "test:unit": "yarn library:test:unit",
37
+ "test:unit-with-coverage": "yarn library:test:unit-with-coverage",
38
+ "visual-test:build": "yarn visual-test:build:typescript && yarn visual-test:build:vite",
39
+ "visual-test:build:typescript": "tsc -p visual-testing",
40
+ "visual-test:build:vite": "vite build --force --config visual-testing/vite.config.js",
41
+ "visual-test:dev": "concurrently -n 'viz:typescript,viz:vite,viz:serve' 'yarn visual-test:dev:typescript' 'yarn visual-test:dev:vite' 'yarn visual-test:dev:serve'",
42
+ "visual-test:dev:serve": "vite --config visual-testing/vite.config.js",
43
+ "visual-test:dev:typescript": "tsc -p visual-testing -w",
44
+ "visual-test:dev:vite": "vite build --force --config visual-testing/vite.config.js --watch",
45
+ "visual-test:report": "backstop --config backstop.config.cjs openReport",
46
+ "visual-test:test": "backstop --config backstop.config.cjs test"
30
47
  },
31
48
  "types": "./index.d.ts",
32
49
  "dependencies": {
33
- "@devvit/protos": "0.9.4",
34
- "@devvit/runtimes": "0.9.4",
50
+ "@devvit/protos": "0.9.5",
51
+ "@devvit/runtimes": "0.9.5",
35
52
  "@lottiefiles/lottie-player": "1.7.1",
36
53
  "p-queue": "7.3.4",
37
54
  "rxjs": "7.5.7"
@@ -56,14 +73,15 @@
56
73
  "lit": "^2.0.0"
57
74
  },
58
75
  "devDependencies": {
59
- "@devvit/eslint-config": "0.9.4",
60
- "@devvit/public-api": "0.9.4",
61
- "@devvit/repo-tools": "0.9.4",
62
- "@devvit/tsconfig": "0.9.4",
76
+ "@devvit/eslint-config": "0.9.5",
77
+ "@devvit/public-api": "0.9.5",
78
+ "@devvit/repo-tools": "0.9.5",
79
+ "@devvit/tsconfig": "0.9.5",
63
80
  "@lit/localize": "0.11.4",
64
81
  "@reddit/baseplate": "0.14.0",
65
82
  "@reddit/eslint-plugin-i18n-shreddit": "0.1.0",
66
83
  "autoprefixer": "10.4.14",
84
+ "backstopjs": "6.2.1",
67
85
  "chokidar": "3.5.3",
68
86
  "concurrently": "7.5.0",
69
87
  "debounce": "1.2.1",
@@ -75,11 +93,12 @@
75
93
  "postcss-import": "15.1.0",
76
94
  "tailwindcss": "3.3.1",
77
95
  "typescript": "4.9.3",
96
+ "vite": "4.3.1",
78
97
  "vitest": "0.8.2"
79
98
  },
80
99
  "publishConfig": {
81
100
  "directory": "dist"
82
101
  },
83
102
  "source": "./src/index.ts",
84
- "gitHead": "27a5a627334932929b427700f6d6686683689a4f"
103
+ "gitHead": "b3ceb34ca798b456b348f59dfb93846ebe19b236"
85
104
  }
@@ -1 +1 @@
1
- {"version":3,"file":"blocks.d.ts","sourceRoot":"","sources":["../../src/server/blocks.ts"],"names":[],"mappings":"AAAA,OAAO,kEAAkE,CAAC;AAC1E,cAAc,oBAAoB,CAAC"}
1
+ {"version":3,"file":"blocks.d.ts","sourceRoot":"","sources":["../../library/src/server/blocks.ts"],"names":[],"mappings":"AAAA,OAAO,kEAAkE,CAAC;AAC1E,cAAc,oBAAoB,CAAC"}
package/styles.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../src/styles.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,MAAM,yBAA8B,CAAC"}
1
+ {"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../library/src/styles.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,MAAM,yBAA8B,CAAC"}