@plasmicpkgs/plasmic-rich-components 1.0.80 → 1.0.81
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/dist/index.js
CHANGED
|
@@ -194,9 +194,10 @@ function deriveValueType(cconfig) {
|
|
|
194
194
|
}
|
|
195
195
|
function buildFieldsPropType(opts) {
|
|
196
196
|
function getDefaultValueHint(field) {
|
|
197
|
-
return function (
|
|
198
|
-
|
|
199
|
-
|
|
197
|
+
return function (_props, contextData, _a) {
|
|
198
|
+
var item = _a.item;
|
|
199
|
+
if (item.fieldId) {
|
|
200
|
+
var fieldSetting = contextData === null || contextData === void 0 ? void 0 : contextData.mergedFields.find(function (f) { return f.fieldId === item.fieldId; });
|
|
200
201
|
return fieldSetting === null || fieldSetting === void 0 ? void 0 : fieldSetting[field];
|
|
201
202
|
}
|
|
202
203
|
return undefined;
|
|
@@ -1663,7 +1664,10 @@ var dataTableMeta = {
|
|
|
1663
1664
|
displayName: "Row key",
|
|
1664
1665
|
helpText: "Column key to use as row key; can also be a function that takes in a row and returns a key value",
|
|
1665
1666
|
hidden: function (ps) { return !ps.canSelectRows || ps.canSelectRows === "none"; },
|
|
1666
|
-
defaultValueHint: function (ps) {
|
|
1667
|
+
defaultValueHint: function (ps) {
|
|
1668
|
+
var derivedRowKey = deriveRowKey(ps.data, ps.rowKey);
|
|
1669
|
+
return derivedRowKey !== undefined ? "".concat(derivedRowKey) : undefined;
|
|
1670
|
+
},
|
|
1667
1671
|
},
|
|
1668
1672
|
selectedRowKey: {
|
|
1669
1673
|
type: "string",
|