@plasmicpkgs/plasmic-cms 0.0.105 → 0.0.108
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/plasmic-cms.cjs.development.js +12 -4
- package/dist/plasmic-cms.cjs.development.js.map +1 -1
- package/dist/plasmic-cms.cjs.production.min.js +1 -1
- package/dist/plasmic-cms.cjs.production.min.js.map +1 -1
- package/dist/plasmic-cms.esm.js +12 -4
- package/dist/plasmic-cms.esm.js.map +1 -1
- package/package.json +3 -3
|
@@ -1116,15 +1116,21 @@ var tablesContextKey = contextPrefix + "Tables";
|
|
|
1116
1116
|
var collectionResultSuffix = "Collection";
|
|
1117
1117
|
|
|
1118
1118
|
var mkQueryContextKey = function mkQueryContextKey(table) {
|
|
1119
|
-
return "" + contextPrefix + table + collectionResultSuffix;
|
|
1119
|
+
return "" + contextPrefix + capitalizeFirst(table) + collectionResultSuffix;
|
|
1120
1120
|
};
|
|
1121
1121
|
|
|
1122
1122
|
var itemContextSuffix = "Item";
|
|
1123
1123
|
|
|
1124
1124
|
var mkRowContextKey = function mkRowContextKey(table) {
|
|
1125
|
-
return "" + contextPrefix + table + itemContextSuffix;
|
|
1125
|
+
return "" + contextPrefix + capitalizeFirst(table) + itemContextSuffix;
|
|
1126
1126
|
};
|
|
1127
1127
|
|
|
1128
|
+
function capitalizeFirst(str) {
|
|
1129
|
+
var _str$at;
|
|
1130
|
+
|
|
1131
|
+
return ((_str$at = str.at(0)) == null ? void 0 : _str$at.toUpperCase()) + str.slice(1);
|
|
1132
|
+
}
|
|
1133
|
+
|
|
1128
1134
|
function useDatabase() {
|
|
1129
1135
|
return host.useSelector(databaseContextKey);
|
|
1130
1136
|
}
|
|
@@ -1133,7 +1139,8 @@ function DatabaseProvider(_ref) {
|
|
|
1133
1139
|
children = _ref.children;
|
|
1134
1140
|
return React__default.createElement(host.DataProvider, {
|
|
1135
1141
|
name: databaseContextKey,
|
|
1136
|
-
data: config
|
|
1142
|
+
data: config,
|
|
1143
|
+
hidden: true
|
|
1137
1144
|
}, children);
|
|
1138
1145
|
}
|
|
1139
1146
|
function useTables() {
|
|
@@ -1144,7 +1151,8 @@ function TablesProvider(_ref2) {
|
|
|
1144
1151
|
tables = _ref2.tables;
|
|
1145
1152
|
return React__default.createElement(host.DataProvider, {
|
|
1146
1153
|
name: tablesContextKey,
|
|
1147
|
-
data: tables
|
|
1154
|
+
data: tables,
|
|
1155
|
+
hidden: true
|
|
1148
1156
|
}, children);
|
|
1149
1157
|
}
|
|
1150
1158
|
|