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/package.json
CHANGED
@@ -19,21 +19,15 @@ export const CollectionContextProvider = (props) => {
|
|
19
19
|
const [selected, setSelected] = useState(null)
|
20
20
|
|
21
21
|
useEffect(() => {
|
22
|
-
|
23
|
-
console.log("CONTEXT LOAD for Filters", filters, customFilters)
|
24
22
|
let mounted = true;
|
25
|
-
|
26
23
|
const callLoad = async () => {
|
27
24
|
const data = await load()
|
28
25
|
if (mounted) setAll(data)
|
29
26
|
}
|
30
27
|
callLoad()
|
31
|
-
|
32
28
|
return () => {
|
33
|
-
console.log("CONTEXT UNMOUNT", filters, customFilters)
|
34
29
|
mounted = false;
|
35
30
|
}
|
36
|
-
|
37
31
|
}, [filters, customFilters])
|
38
32
|
|
39
33
|
async function load() {
|
@@ -92,14 +86,6 @@ export const CollectionContextProvider = (props) => {
|
|
92
86
|
}
|
93
87
|
}
|
94
88
|
|
95
|
-
/*
|
96
|
-
async function reloadSelection() {
|
97
|
-
const result = await this.fetch(this.selected.id)
|
98
|
-
this.selected = result
|
99
|
-
}
|
100
|
-
|
101
|
-
|
102
|
-
|
103
89
|
async function create(form) {
|
104
90
|
try {
|
105
91
|
if (versioning) form.version = 1
|
@@ -110,6 +96,13 @@ export const CollectionContextProvider = (props) => {
|
|
110
96
|
}
|
111
97
|
return
|
112
98
|
}
|
99
|
+
|
100
|
+
/*
|
101
|
+
async function reloadSelection() {
|
102
|
+
const result = await this.fetch(this.selected.id)
|
103
|
+
this.selected = result
|
104
|
+
}
|
105
|
+
|
113
106
|
|
114
107
|
async function update(form) {
|
115
108
|
try {
|
@@ -23,7 +23,7 @@ export const CollectionPage = (props) => {
|
|
23
23
|
|
24
24
|
return (
|
25
25
|
<div className={`collection-page ${layout}`}>
|
26
|
-
<CollectionContextProvider host={host} url={url} filtersValue={filtersValue}>
|
26
|
+
<CollectionContextProvider host={host} url={url} filtersValue={filtersValue} versioning={false}>
|
27
27
|
<Header title={title} >
|
28
28
|
{actions}
|
29
29
|
</Header>
|
package/src/domain2/index.js
CHANGED
@@ -2,7 +2,6 @@ import React, { useRef, useMemo, useEffect, useState } from "react";
|
|
2
2
|
import './ImageViewer.css'
|
3
3
|
|
4
4
|
const ImageViewerTest = (props) => {
|
5
|
-
|
6
5
|
return (
|
7
6
|
<div>
|
8
7
|
<h1>ImageViewerTest</h1>
|
@@ -124,7 +123,7 @@ export const ImageViewer = ({ image }) => {
|
|
124
123
|
}, [zoom, offset]);
|
125
124
|
|
126
125
|
return (
|
127
|
-
<div ref={containerRef}>
|
126
|
+
<div className="image-viewer" ref={containerRef}>
|
128
127
|
<canvas
|
129
128
|
onMouseDown={handleMouseDown}
|
130
129
|
onMouseUp={handleMouseUp}
|