@devvit/ui-renderer 0.10.8-next-2023-10-23-a3ea9102b.0 → 0.10.8-next-2023-10-23-07512eb25.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/blocks/attributes.js
CHANGED
|
@@ -62,7 +62,7 @@ export function sizingStyle(sizing) {
|
|
|
62
62
|
}
|
|
63
63
|
export function paddingClass(padding) {
|
|
64
64
|
return {
|
|
65
|
-
'p-0': padding === undefined || padding
|
|
65
|
+
'p-0': padding === undefined || padding === BlockPadding.PADDING_NONE,
|
|
66
66
|
'p-2xs': padding === BlockPadding.PADDING_XSMALL,
|
|
67
67
|
'p-xs': padding === BlockPadding.PADDING_SMALL,
|
|
68
68
|
'p-md': padding === BlockPadding.PADDING_MEDIUM,
|
|
@@ -386,7 +386,7 @@ export function textOverflowClass(config) {
|
|
|
386
386
|
const overflow = config.overflow;
|
|
387
387
|
return {
|
|
388
388
|
'overflow-hidden': true,
|
|
389
|
-
'text-clip': overflow === BlockTextOverflow.TEXT_OVERFLOW_CLIP || overflow
|
|
389
|
+
'text-clip': overflow === BlockTextOverflow.TEXT_OVERFLOW_CLIP || overflow === undefined,
|
|
390
390
|
'text-ellipsis': overflow === BlockTextOverflow.TEXT_OVERFLOW_ELLIPSE,
|
|
391
391
|
'whitespace-pre-line': wrap,
|
|
392
392
|
'whitespace-nowrap': !wrap,
|
|
@@ -90,7 +90,7 @@ export function brightnessByColor(color) {
|
|
|
90
90
|
let g;
|
|
91
91
|
let b;
|
|
92
92
|
if (isHEX) {
|
|
93
|
-
const hasFullSpec = color.length
|
|
93
|
+
const hasFullSpec = color.length === 7;
|
|
94
94
|
const m = color.substring(1).match(hasFullSpec ? /(\S{2})/g : /(\S)/g);
|
|
95
95
|
if (m) {
|
|
96
96
|
r = parseInt(m[0] + (hasFullSpec ? '' : m[0]), 16);
|
|
@@ -80,7 +80,7 @@ export function renderBlock(block, ctx) {
|
|
|
80
80
|
break;
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
|
-
if (block.size?.grow
|
|
83
|
+
if (block.size?.grow === true && ctx.stackDirection !== BlockStackDirection.STACK_DEPTH) {
|
|
84
84
|
return html `<div class="grid grid-cols-1 flex-grow flex-shrink">${render}</div>`;
|
|
85
85
|
}
|
|
86
86
|
else {
|
package/blocks/templates/util.js
CHANGED
|
@@ -88,7 +88,7 @@ export function getSizes(block) {
|
|
|
88
88
|
return (block.sizes ??
|
|
89
89
|
(block.size
|
|
90
90
|
? {
|
|
91
|
-
width: block.size.width
|
|
91
|
+
width: block.size.width !== undefined
|
|
92
92
|
? {
|
|
93
93
|
value: {
|
|
94
94
|
value: block.size.width,
|
|
@@ -96,7 +96,7 @@ export function getSizes(block) {
|
|
|
96
96
|
},
|
|
97
97
|
}
|
|
98
98
|
: undefined,
|
|
99
|
-
height: block.size.height
|
|
99
|
+
height: block.size.height !== undefined
|
|
100
100
|
? {
|
|
101
101
|
value: {
|
|
102
102
|
value: block.size.height,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devvit/ui-renderer",
|
|
3
|
-
"version": "0.10.8-next-2023-10-23-
|
|
3
|
+
"version": "0.10.8-next-2023-10-23-07512eb25.0",
|
|
4
4
|
"license": "BSD-3-Clause",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -52,9 +52,9 @@
|
|
|
52
52
|
},
|
|
53
53
|
"types": "./index.d.ts",
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@devvit/protos": "0.10.8-next-2023-10-23-
|
|
56
|
-
"@devvit/runtime-lite": "0.10.8-next-2023-10-23-
|
|
57
|
-
"@devvit/runtimes": "0.10.8-next-2023-10-23-
|
|
55
|
+
"@devvit/protos": "0.10.8-next-2023-10-23-07512eb25.0",
|
|
56
|
+
"@devvit/runtime-lite": "0.10.8-next-2023-10-23-07512eb25.0",
|
|
57
|
+
"@devvit/runtimes": "0.10.8-next-2023-10-23-07512eb25.0",
|
|
58
58
|
"@lottiefiles/lottie-player": "1.7.1",
|
|
59
59
|
"p-queue": "7.3.4",
|
|
60
60
|
"rxjs": "7.5.7"
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"devDependencies": {
|
|
82
82
|
"@devvit/eslint-config": "0.10.7",
|
|
83
83
|
"@devvit/repo-tools": "0.10.7",
|
|
84
|
-
"@devvit/tsconfig": "0.10.8-next-2023-10-23-
|
|
84
|
+
"@devvit/tsconfig": "0.10.8-next-2023-10-23-07512eb25.0",
|
|
85
85
|
"@lit/localize": "0.11.4",
|
|
86
86
|
"@open-wc/testing-helpers": "2.3.0",
|
|
87
87
|
"@reddit/baseplate": "0.14.0",
|
|
@@ -110,5 +110,5 @@
|
|
|
110
110
|
"directory": "dist"
|
|
111
111
|
},
|
|
112
112
|
"source": "./src/index.ts",
|
|
113
|
-
"gitHead": "
|
|
113
|
+
"gitHead": "97c5e6088cf1954605422b1ca37637e899eaf610"
|
|
114
114
|
}
|