@beseif-solutions/prow-core 1.2.3 → 1.3.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.
|
@@ -89,7 +89,7 @@ class Context {
|
|
|
89
89
|
if (serialized) {
|
|
90
90
|
resolved = resolved.replace(`"${expression}"`, (lodash_1.default.isObject(get) || lodash_1.default.isString(get)) ? JSON.stringify(get) : get);
|
|
91
91
|
}
|
|
92
|
-
resolved = resolved.replace(expression, lodash_1.default.toString(get));
|
|
92
|
+
resolved = resolved.replace(expression, lodash_1.default.isObject(get) ? JSON.stringify(get) : lodash_1.default.toString(get));
|
|
93
93
|
}
|
|
94
94
|
else {
|
|
95
95
|
resolved = resolved.replace(expression, ``);
|
|
@@ -137,6 +137,7 @@ const localizeProperties = (t, element) => {
|
|
|
137
137
|
return {
|
|
138
138
|
name: t(`${element.id}.name`, { fallback: true }),
|
|
139
139
|
description: t(`${element.id}.description`),
|
|
140
|
+
information: t(`${element.id}.information`),
|
|
140
141
|
...help && { help: help },
|
|
141
142
|
...instructions && { instructions: instructions },
|
|
142
143
|
};
|
package/package.json
CHANGED
|
@@ -102,7 +102,7 @@ class Context {
|
|
|
102
102
|
if (_.has(clonedData, path)) {
|
|
103
103
|
const get = _.get(clonedData, path);
|
|
104
104
|
if (serialized) { resolved = resolved.replace(`"${expression}"`, (_.isObject(get) || _.isString(get)) ? JSON.stringify(get) : get); }
|
|
105
|
-
resolved = resolved.replace(expression, _.toString(get));
|
|
105
|
+
resolved = resolved.replace(expression, _.isObject(get) ? JSON.stringify(get) : _.toString(get));
|
|
106
106
|
} else { resolved = resolved.replace(expression, ``); }
|
|
107
107
|
}
|
|
108
108
|
}
|
|
@@ -18,6 +18,7 @@ export type LocalizedField = {
|
|
|
18
18
|
export type LocalizedProperties = {
|
|
19
19
|
name: string,
|
|
20
20
|
description: string,
|
|
21
|
+
information?: string,
|
|
21
22
|
help?: Record<string, string>,
|
|
22
23
|
instructions?: string,
|
|
23
24
|
};
|
|
@@ -192,6 +193,7 @@ export const localizeProperties = (
|
|
|
192
193
|
return {
|
|
193
194
|
name: t(`${element.id}.name`, { fallback: true }),
|
|
194
195
|
description: t(`${element.id}.description`),
|
|
196
|
+
information: t(`${element.id}.information`),
|
|
195
197
|
...help && { help: help },
|
|
196
198
|
...instructions && { instructions: instructions },
|
|
197
199
|
};
|