ywana-core8 0.0.791 → 0.0.792
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.cjs +17 -25
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +17 -26
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +17 -25
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/domain2/CollectionContext.js +7 -14
- package/src/domain2/CollectionPage.js +1 -1
- package/src/domain2/index.js +2 -1
- package/src/widgets/image/ImageViewer.js +1 -2
package/dist/index.modern.js
CHANGED
@@ -3055,6 +3055,7 @@ var ImageViewer = function ImageViewer(_ref) {
|
|
3055
3055
|
draw();
|
3056
3056
|
}, [zoom, offset]);
|
3057
3057
|
return /*#__PURE__*/React.createElement("div", {
|
3058
|
+
className: "image-viewer",
|
3058
3059
|
ref: containerRef
|
3059
3060
|
}, /*#__PURE__*/React.createElement("canvas", {
|
3060
3061
|
onMouseDown: handleMouseDown,
|
@@ -10832,33 +10833,12 @@ function _catch(body, recover) {
|
|
10832
10833
|
|
10833
10834
|
var CollectionContext = React.createContext();
|
10834
10835
|
var CollectionContextProvider = function CollectionContextProvider(props) {
|
10835
|
-
var fetch = function fetch(id) {
|
10836
|
-
try {
|
10837
|
-
return Promise.resolve(_catch(function () {
|
10838
|
-
return Promise.resolve(API.find(id));
|
10839
|
-
}, function (error) {
|
10840
|
-
console.log(error);
|
10841
|
-
}));
|
10842
|
-
} catch (e) {
|
10843
|
-
return Promise.reject(e);
|
10844
|
-
}
|
10845
|
-
};
|
10846
10836
|
/*
|
10847
10837
|
async function reloadSelection() {
|
10848
10838
|
const result = await this.fetch(this.selected.id)
|
10849
10839
|
this.selected = result
|
10850
10840
|
}
|
10851
|
-
|
10852
|
-
try {
|
10853
|
-
if (versioning) form.version = 1
|
10854
|
-
await API.create(form);
|
10855
|
-
await this.load();
|
10856
|
-
} catch (error) {
|
10857
|
-
console.log(error)
|
10858
|
-
}
|
10859
|
-
return
|
10860
|
-
}
|
10861
|
-
async function update(form) {
|
10841
|
+
async function update(form) {
|
10862
10842
|
try {
|
10863
10843
|
if (versioning) form.version = form.version ? form.version + 1 : 1
|
10864
10844
|
await API.update(form)
|
@@ -10899,6 +10879,18 @@ var CollectionContextProvider = function CollectionContextProvider(props) {
|
|
10899
10879
|
*/
|
10900
10880
|
|
10901
10881
|
|
10882
|
+
var fetch = function fetch(id) {
|
10883
|
+
try {
|
10884
|
+
return Promise.resolve(_catch(function () {
|
10885
|
+
return Promise.resolve(API.find(id));
|
10886
|
+
}, function (error) {
|
10887
|
+
console.log(error);
|
10888
|
+
}));
|
10889
|
+
} catch (e) {
|
10890
|
+
return Promise.reject(e);
|
10891
|
+
}
|
10892
|
+
};
|
10893
|
+
|
10902
10894
|
var removeCustomFilter = function removeCustomFilter(id) {
|
10903
10895
|
try {
|
10904
10896
|
var next = _extends({}, customFilters);
|
@@ -11010,7 +11002,6 @@ var CollectionContextProvider = function CollectionContextProvider(props) {
|
|
11010
11002
|
setSelected = _useState6[1];
|
11011
11003
|
|
11012
11004
|
useEffect(function () {
|
11013
|
-
console.log("CONTEXT LOAD for Filters", filters, customFilters);
|
11014
11005
|
var mounted = true;
|
11015
11006
|
|
11016
11007
|
var callLoad = function callLoad() {
|
@@ -11021,7 +11012,6 @@ var CollectionContextProvider = function CollectionContextProvider(props) {
|
|
11021
11012
|
|
11022
11013
|
callLoad();
|
11023
11014
|
return function () {
|
11024
|
-
console.log("CONTEXT UNMOUNT", filters, customFilters);
|
11025
11015
|
mounted = false;
|
11026
11016
|
};
|
11027
11017
|
}, [filters, customFilters]);
|
@@ -11403,7 +11393,8 @@ var CollectionPage = function CollectionPage(props) {
|
|
11403
11393
|
}, /*#__PURE__*/React.createElement(CollectionContextProvider, {
|
11404
11394
|
host: host,
|
11405
11395
|
url: url,
|
11406
|
-
filtersValue: filtersValue
|
11396
|
+
filtersValue: filtersValue,
|
11397
|
+
versioning: false
|
11407
11398
|
}, /*#__PURE__*/React.createElement(Header, {
|
11408
11399
|
title: title
|
11409
11400
|
}, actions), canFilter ? /*#__PURE__*/React.createElement(CollectionFilters, {
|
@@ -11424,5 +11415,5 @@ var isFunction = function isFunction(value) {
|
|
11424
11415
|
return value && (Object.prototype.toString.call(value) === "[object Function]" || "function" === typeof value || value instanceof Function);
|
11425
11416
|
};
|
11426
11417
|
|
11427
|
-
export { Accordion, Avatar, Button, Calendar, CheckBox, Chip, Chips, CircularProgress, CollectionContext$1 as CollectionContext, CollectionContext as CollectionContext2, CollectionEditor$2 as CollectionEditor, CollectionFilters$1 as CollectionFilters, CollectionPage$1 as CollectionPage, CollectionPage as CollectionPage2, CollectionTree, ColorField, Content, ContentEditor, ContentForm, ContentViewer, CreateContentDialog, DataTable, DateRange, Dialog, DropDown, EditContentDialog, EmptyMessage, FORMATS$1 as FORMATS, FieldEditor, FileExplorer, FilesGrid, Form, HTTPClient, Header, Icon, ImageViewer, Kanban, KanbanCard, KanbanColumn, LinearProgress, List, ListEditor, LoginBox, Menu, MenuIcon, MenuItem, MenuSeparator, MultiSelector, Page, PageContext, PageProvider, PasswordEditor, PasswordField, Planner, Property, RadioButton, ResetPasswordBox, Section, Session, Site, SiteContext, SiteProvider, Stack, Switch, TEXTFORMATS, TYPES, Tab, TabbedContentEditor, TabbedTablePage, TabbedView, TableEditor$2 as TableEditor, TablePage, TablePage2, Tabs, TaskContext, TaskContextProvider, TaskMonitor, TaskProgress, Text, TextArea, TextField, Thumbnail, ToggleButton, TokenField, Tooltip, Tree, TreeItem, TreeNode, TreededContentEditor, UploadArea, UploadDialog, UploadFile, UploadIcon, Uploader, View, Viewer, WaitScreen, Wizard, WizardContext, isEmpty, isFunction };
|
11418
|
+
export { Accordion, Avatar, Button, Calendar, CheckBox, Chip, Chips, CircularProgress, CollectionContext$1 as CollectionContext, CollectionContext as CollectionContext2, CollectionEditor$2 as CollectionEditor, CollectionFilters$1 as CollectionFilters, CollectionPage$1 as CollectionPage, CollectionPage as CollectionPage2, CollectionTree, ColorField, Content, ContentEditor, ContentForm, ContentViewer, CreateContentDialog, DataTable, DateRange, Dialog, DropDown, DynamicForm, EditContentDialog, EmptyMessage, FORMATS$1 as FORMATS, FieldEditor, FileExplorer, FilesGrid, Form, HTTPClient, Header, Icon, ImageViewer, Kanban, KanbanCard, KanbanColumn, LinearProgress, List, ListEditor, LoginBox, Menu, MenuIcon, MenuItem, MenuSeparator, MultiSelector, Page, PageContext, PageProvider, PasswordEditor, PasswordField, Planner, Property, RadioButton, ResetPasswordBox, Section, Session, Site, SiteContext, SiteProvider, Stack, Switch, TEXTFORMATS, TYPES, Tab, TabbedContentEditor, TabbedTablePage, TabbedView, TableEditor$2 as TableEditor, TablePage, TablePage2, Tabs, TaskContext, TaskContextProvider, TaskMonitor, TaskProgress, Text, TextArea, TextField, Thumbnail, ToggleButton, TokenField, Tooltip, Tree, TreeItem, TreeNode, TreededContentEditor, UploadArea, UploadDialog, UploadFile, UploadIcon, Uploader, View, Viewer, WaitScreen, Wizard, WizardContext, isEmpty, isFunction };
|
11428
11419
|
//# sourceMappingURL=index.modern.js.map
|