kfb-view 2.2.7 → 2.2.9

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.
@@ -38,7 +38,8 @@
38
38
  <component name="ChangeListManager">
39
39
  <list default="true" id="55024232-8108-4dc9-9bd3-0fd2aa2f34f8" name="Default Changelist" comment="">
40
40
  <change beforePath="$PROJECT_DIR$/package.json" beforeDir="false" afterPath="$PROJECT_DIR$/package.json" afterDir="false" />
41
- <change beforePath="$PROJECT_DIR$/src/tool/Image.js" beforeDir="false" afterPath="$PROJECT_DIR$/src/tool/Image.js" afterDir="false" />
41
+ <change beforePath="$PROJECT_DIR$/src/components/area/index.js" beforeDir="false" afterPath="$PROJECT_DIR$/src/components/area/index.js" afterDir="false" />
42
+ <change beforePath="$PROJECT_DIR$/src/view.js" beforeDir="false" afterPath="$PROJECT_DIR$/src/view.js" afterDir="false" />
42
43
  </list>
43
44
  <option name="SHOW_DIALOG" value="false" />
44
45
  <option name="HIGHLIGHT_CONFLICTS" value="true" />
@@ -74,21 +75,22 @@
74
75
  <option name="hideEmptyMiddlePackages" value="true" />
75
76
  <option name="showLibraryContents" value="true" />
76
77
  </component>
77
- <component name="PropertiesComponent">{
78
- &quot;keyToString&quot;: {
79
- &quot;DefaultHtmlFileTemplate&quot;: &quot;HTML File&quot;,
80
- &quot;WebServerToolWindowFactoryState&quot;: &quot;false&quot;,
81
- &quot;dart.analysis.tool.window.visible&quot;: &quot;false&quot;,
82
- &quot;last_opened_file_path&quot;: &quot;/home/fanqifeng/WebstormProjects/kfb-view&quot;,
83
- &quot;node.js.detected.package.eslint&quot;: &quot;true&quot;,
84
- &quot;node.js.selected.package.eslint&quot;: &quot;(autodetect)&quot;,
85
- &quot;nodejs_interpreter_path&quot;: &quot;/home/fanqifeng/.nvm/versions/node/v10.15.1/bin/node&quot;,
86
- &quot;nodejs_package_manager_path&quot;: &quot;npm&quot;,
87
- &quot;settings.editor.selected.configurable&quot;: &quot;settings.nodejs&quot;,
88
- &quot;ts.external.directory.path&quot;: &quot;/opt/WebStorm/plugins/JavaScriptLanguage/jsLanguageServicesImpl/external&quot;,
89
- &quot;vue.rearranger.settings.migration&quot;: &quot;true&quot;
78
+ <component name="PropertiesComponent"><![CDATA[{
79
+ "keyToString": {
80
+ "DefaultHtmlFileTemplate": "HTML File",
81
+ "Project.color": "4c401d",
82
+ "WebServerToolWindowFactoryState": "false",
83
+ "dart.analysis.tool.window.visible": "false",
84
+ "last_opened_file_path": "/home/fanqifeng/WebstormProjects/kfb-view",
85
+ "node.js.detected.package.eslint": "true",
86
+ "node.js.selected.package.eslint": "(autodetect)",
87
+ "nodejs_interpreter_path": "/home/fanqifeng/.nvm/versions/node/v10.15.1/bin/node",
88
+ "nodejs_package_manager_path": "npm",
89
+ "settings.editor.selected.configurable": "settings.nodejs",
90
+ "ts.external.directory.path": "/opt/WebStorm/plugins/JavaScriptLanguage/jsLanguageServicesImpl/external",
91
+ "vue.rearranger.settings.migration": "true"
90
92
  }
91
- }</component>
93
+ }]]></component>
92
94
  <component name="RecentsManager">
93
95
  <key name="CopyFile.RECENT_KEYS">
94
96
  <recent name="$PROJECT_DIR$/example" />
@@ -105,7 +107,7 @@
105
107
  <recent name="$PROJECT_DIR$/src/tool" />
106
108
  </key>
107
109
  </component>
108
- <component name="RunManager" selected="npm.build:lib">
110
+ <component name="RunManager" selected="npm.server:hot">
109
111
  <configuration name="build:lib" type="js.build_tools.npm" temporary="true" nameIsGenerated="true">
110
112
  <package-json value="$PROJECT_DIR$/package.json" />
111
113
  <command value="run" />
@@ -168,8 +170,8 @@
168
170
  </list>
169
171
  <recent_temporary>
170
172
  <list>
171
- <item itemvalue="npm.build:lib" />
172
173
  <item itemvalue="npm.server:hot" />
174
+ <item itemvalue="npm.build:lib" />
173
175
  <item itemvalue="npm.clean:lib" />
174
176
  <item itemvalue="npm.server" />
175
177
  <item itemvalue="npm.build:prod" />
@@ -317,29 +319,26 @@
317
319
  <workItem from="1659952433819" duration="4309000" />
318
320
  <workItem from="1660003953397" duration="1603000" />
319
321
  <workItem from="1660273781421" duration="1360000" />
320
- <workItem from="1660291265906" duration="619000" />
321
- <workItem from="1660292148490" duration="530000" />
322
- </task>
323
- <task id="LOCAL-00046" summary="优化,增加部分注释">
324
- <created>1646292963908</created>
325
- <option name="number" value="00046" />
326
- <option name="presentableId" value="LOCAL-00046" />
327
- <option name="project" value="LOCAL" />
328
- <updated>1646292963908</updated>
329
- </task>
330
- <task id="LOCAL-00047" summary="2.1.8">
331
- <created>1646292978431</created>
332
- <option name="number" value="00047" />
333
- <option name="presentableId" value="LOCAL-00047" />
334
- <option name="project" value="LOCAL" />
335
- <updated>1646292978431</updated>
336
- </task>
337
- <task id="LOCAL-00048" summary="TerserPlugin">
338
- <created>1646293408931</created>
339
- <option name="number" value="00048" />
340
- <option name="presentableId" value="LOCAL-00048" />
341
- <option name="project" value="LOCAL" />
342
- <updated>1646293408931</updated>
322
+ <workItem from="1660291265906" duration="622000" />
323
+ <workItem from="1660354678944" duration="1028000" />
324
+ <workItem from="1660372146258" duration="2000" />
325
+ <workItem from="1660524325887" duration="6231000" />
326
+ <workItem from="1660544268877" duration="1196000" />
327
+ <workItem from="1660559304089" duration="596000" />
328
+ <workItem from="1660609864291" duration="1272000" />
329
+ <workItem from="1660618324918" duration="598000" />
330
+ <workItem from="1660644014789" duration="599000" />
331
+ <workItem from="1660695374925" duration="593000" />
332
+ <workItem from="1660702683815" duration="681000" />
333
+ <workItem from="1660887408534" duration="1827000" />
334
+ <workItem from="1660892708510" duration="599000" />
335
+ <workItem from="1661049918925" duration="597000" />
336
+ <workItem from="1661073417704" duration="594000" />
337
+ <workItem from="1661133652371" duration="599000" />
338
+ <workItem from="1661147230248" duration="648000" />
339
+ <workItem from="1661304066625" duration="1482000" />
340
+ <workItem from="1661307403631" duration="1194000" />
341
+ <workItem from="1663305397647" duration="5412000" />
343
342
  </task>
344
343
  <task id="LOCAL-00049" summary="2.1.9">
345
344
  <created>1646293508969</created>
@@ -656,14 +655,35 @@
656
655
  <option name="project" value="LOCAL" />
657
656
  <updated>1659956059809</updated>
658
657
  </task>
659
- <task id="LOCAL-00094" summary="2.2.6">
660
- <created>1660292382085</created>
658
+ <task id="LOCAL-00094" summary="2.2.8">
659
+ <created>1660529152942</created>
661
660
  <option name="number" value="00094" />
662
661
  <option name="presentableId" value="LOCAL-00094" />
663
662
  <option name="project" value="LOCAL" />
664
- <updated>1660292382086</updated>
663
+ <updated>1660529152943</updated>
664
+ </task>
665
+ <task id="LOCAL-00095" summary="优化标注信息显示">
666
+ <created>1663307741209</created>
667
+ <option name="number" value="00095" />
668
+ <option name="presentableId" value="LOCAL-00095" />
669
+ <option name="project" value="LOCAL" />
670
+ <updated>1663307741209</updated>
671
+ </task>
672
+ <task id="LOCAL-00096" summary="标注事件回调">
673
+ <created>1663310530025</created>
674
+ <option name="number" value="00096" />
675
+ <option name="presentableId" value="LOCAL-00096" />
676
+ <option name="project" value="LOCAL" />
677
+ <updated>1663310530025</updated>
678
+ </task>
679
+ <task id="LOCAL-00097" summary="2.2.9">
680
+ <created>1663310718298</created>
681
+ <option name="number" value="00097" />
682
+ <option name="presentableId" value="LOCAL-00097" />
683
+ <option name="project" value="LOCAL" />
684
+ <updated>1663310718298</updated>
665
685
  </task>
666
- <option name="localTasksCounter" value="95" />
686
+ <option name="localTasksCounter" value="98" />
667
687
  <servers />
668
688
  </component>
669
689
  <component name="TypeScriptGeneratedFilesManager">
@@ -705,9 +725,6 @@
705
725
  <component name="VcsManagerConfiguration">
706
726
  <option name="CHECK_CODE_SMELLS_BEFORE_PROJECT_COMMIT" value="false" />
707
727
  <option name="LOCAL_CHANGES_DETAILS_PREVIEW_SHOWN" value="false" />
708
- <MESSAGE value="标注时增加右键拖动视野" />
709
- <MESSAGE value="曲线绘制中,按删除键,删除上一个标注点" />
710
- <MESSAGE value="优化点击操作" />
711
728
  <MESSAGE value="enableDbClickClose" />
712
729
  <MESSAGE value="2.1.20" />
713
730
  <MESSAGE value="view.js" />
@@ -729,8 +746,11 @@
729
746
  <MESSAGE value="触发限制优化" />
730
747
  <MESSAGE value="增加图片绘制" />
731
748
  <MESSAGE value="2.2.5" />
732
- <MESSAGE value="2.2.6" />
733
- <option name="LAST_COMMIT_MESSAGE" value="2.2.6" />
749
+ <MESSAGE value="2.2.8" />
750
+ <MESSAGE value="优化标注信息显示" />
751
+ <MESSAGE value="标注事件回调" />
752
+ <MESSAGE value="2.2.9" />
753
+ <option name="LAST_COMMIT_MESSAGE" value="2.2.9" />
734
754
  <option name="REFORMAT_BEFORE_PROJECT_COMMIT" value="true" />
735
755
  </component>
736
756
  <component name="XSLT-Support.FileAssociations.UIState">
package/example/index.js CHANGED
@@ -2,7 +2,7 @@ import {KfbView, hslToRgb, rgbToHsl, cacheGammaTable} from '../src';
2
2
  import axios from 'axios';
3
3
  import {EVENT_DB_CLICK_LABEL} from '../src/const/event';
4
4
 
5
- const fileName = '/upload/large_file/last/2022/06/22/3625ce6de8197c7315ce9e05b4ef233b/IHC.kfb';
5
+ const fileName = '/upload/large_file/last/2022/09/07/fb6f566d15cc52331e3c4f3e1794a748/T2020-00935.kfb';
6
6
 
7
7
  const instance = axios.create({
8
8
  baseURL: '/api',
@@ -55,8 +55,8 @@ instance.get(`/slide/info?file=${fileName}`).then(({data}) => {
55
55
  imageCapRes: data.imageCapRes,
56
56
  },
57
57
  grid: {
58
- show: true,
59
- ruler: true,
58
+ show: false,
59
+ ruler: false,
60
60
  },
61
61
  openSeadragonOptions: {
62
62
  maxZoomLevel: data.scanScale * 10,
@@ -187,9 +187,22 @@ instance.get(`/slide/info?file=${fileName}`).then(({data}) => {
187
187
  );
188
188
  },
189
189
  measure: {
190
- handler(content, label) {
190
+ selectHandler(content, label) {
191
191
  return [...content];
192
192
  },
193
+ handler(content, label) {
194
+ return ['标注类别:ASC-HS'];
195
+ },
196
+ show: true,
197
+ },
198
+ labelDrawing(canvas, label, region) {
199
+ /* console.log(label, region);
200
+ const ctx = canvas.getContext('2d');
201
+ ctx.beginPath();
202
+ ctx.lineWidth = 2;
203
+ ctx.moveTo(region.x, region.y);
204
+ ctx.lineTo(region.x-10, region.y);
205
+ ctx.stroke();*/
193
206
  },
194
207
  labelList: [
195
208
  {