mapshaper 0.7.9 → 0.7.10
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/bin/mapshaper-gui +1 -0
- package/mapshaper.js +1818 -52
- package/package.json +6 -3
- package/www/index.html +16 -1
- package/www/mapshaper-gui.js +9321 -5437
- package/www/mapshaper.js +1818 -52
- package/www/page.css +73 -0
- package/www/ai-config.js +0 -62
package/www/page.css
CHANGED
|
@@ -253,6 +253,10 @@ body.map-view {
|
|
|
253
253
|
z-index: 50;
|
|
254
254
|
}
|
|
255
255
|
|
|
256
|
+
.history-menu-dropdown {
|
|
257
|
+
pointer-events: none;
|
|
258
|
+
}
|
|
259
|
+
|
|
256
260
|
.header-menu-item {
|
|
257
261
|
display: block;
|
|
258
262
|
padding: 4px 14px;
|
|
@@ -261,6 +265,7 @@ body.map-view {
|
|
|
261
265
|
line-height: 1.3;
|
|
262
266
|
text-decoration: none;
|
|
263
267
|
white-space: nowrap;
|
|
268
|
+
cursor: pointer;
|
|
264
269
|
}
|
|
265
270
|
|
|
266
271
|
.header-menu-item:hover,
|
|
@@ -270,6 +275,51 @@ body.map-view {
|
|
|
270
275
|
outline: none;
|
|
271
276
|
}
|
|
272
277
|
|
|
278
|
+
.header-menu-item.disabled {
|
|
279
|
+
color: #999;
|
|
280
|
+
pointer-events: none;
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
.history-menu-dropdown .info-box {
|
|
284
|
+
pointer-events: initial;
|
|
285
|
+
min-width: 230px;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
.history-menu-item {
|
|
289
|
+
color: #333;
|
|
290
|
+
cursor: pointer;
|
|
291
|
+
padding: 2px 0;
|
|
292
|
+
white-space: nowrap;
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
.history-menu-item:hover,
|
|
296
|
+
.history-menu-item:focus {
|
|
297
|
+
color: #1A6A96;
|
|
298
|
+
outline: none;
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
.history-menu-item.disabled {
|
|
302
|
+
color: #999;
|
|
303
|
+
cursor: default;
|
|
304
|
+
opacity: 0.55;
|
|
305
|
+
pointer-events: none;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
.history-menu-separator {
|
|
309
|
+
height: 1px;
|
|
310
|
+
background-color: #ddd;
|
|
311
|
+
margin: 6px 0 5px 0;
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
.history-menu-note {
|
|
315
|
+
color: #777;
|
|
316
|
+
font-size: 12px;
|
|
317
|
+
line-height: 1.25;
|
|
318
|
+
max-width: 215px;
|
|
319
|
+
padding: 0 0 5px 0;
|
|
320
|
+
white-space: normal;
|
|
321
|
+
}
|
|
322
|
+
|
|
273
323
|
.header-menu-item.header-menu-sponsor svg {
|
|
274
324
|
width: 12px;
|
|
275
325
|
height: 12px;
|
|
@@ -763,6 +813,28 @@ body.console-open .map-area {
|
|
|
763
813
|
display: none;
|
|
764
814
|
}
|
|
765
815
|
|
|
816
|
+
.console-tab {
|
|
817
|
+
position: absolute;
|
|
818
|
+
top: 55px; /* below line intersection repair link */
|
|
819
|
+
left: 0;
|
|
820
|
+
z-index: 25;
|
|
821
|
+
writing-mode: vertical-rl;
|
|
822
|
+
transform: rotate(180deg);
|
|
823
|
+
background-color: #1385B7;
|
|
824
|
+
color: white;
|
|
825
|
+
padding: 9px 4px;
|
|
826
|
+
border-radius: 5px 0 0 5px;
|
|
827
|
+
font-size: 13px;
|
|
828
|
+
font-weight: 500;
|
|
829
|
+
cursor: pointer;
|
|
830
|
+
pointer-events: auto;
|
|
831
|
+
}
|
|
832
|
+
|
|
833
|
+
.console-tab:hover,
|
|
834
|
+
body.console-open .console-tab {
|
|
835
|
+
background-color: #1A6A96;
|
|
836
|
+
}
|
|
837
|
+
|
|
766
838
|
.console-window {
|
|
767
839
|
pointer-events: auto;
|
|
768
840
|
background-color: black;
|
|
@@ -1370,6 +1442,7 @@ img.close-btn:hover,
|
|
|
1370
1442
|
overflow: hidden;
|
|
1371
1443
|
overflow-y: auto;
|
|
1372
1444
|
margin: 0 -4px 6px -4px;
|
|
1445
|
+
user-select: text;
|
|
1373
1446
|
}
|
|
1374
1447
|
|
|
1375
1448
|
.message-item {
|
package/www/ai-config.js
DELETED
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
(function() {
|
|
2
|
-
var defaultProvider = "anthropic";
|
|
3
|
-
|
|
4
|
-
var common = {
|
|
5
|
-
enabled: true,
|
|
6
|
-
mode: "direct",
|
|
7
|
-
label: "Ask Mapshaper",
|
|
8
|
-
title: "Ask Mapshaper",
|
|
9
|
-
staticContextUrls: [
|
|
10
|
-
"/docs/ai/bot-instructions.html.md",
|
|
11
|
-
"/docs/ai/command-cheatsheet.html.md",
|
|
12
|
-
"/llms-full.txt"
|
|
13
|
-
],
|
|
14
|
-
sendRuntimeContext: true,
|
|
15
|
-
sendSampleValues: false,
|
|
16
|
-
allowRunCommands: false
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
var providers = {
|
|
20
|
-
anthropic: {
|
|
21
|
-
provider: "anthropic",
|
|
22
|
-
apiKey: "",
|
|
23
|
-
model: "claude-sonnet-4-6",
|
|
24
|
-
cacheControl: {type: "ephemeral"},
|
|
25
|
-
cacheTtl: "1h"
|
|
26
|
-
},
|
|
27
|
-
openai: {
|
|
28
|
-
provider: "openai",
|
|
29
|
-
apiKey: "",
|
|
30
|
-
model: "gpt-4.1-mini"
|
|
31
|
-
},
|
|
32
|
-
gemini: {
|
|
33
|
-
provider: "gemini",
|
|
34
|
-
apiKey: "",
|
|
35
|
-
model: "gemini-3.1-pro-preview"
|
|
36
|
-
},
|
|
37
|
-
mock: {
|
|
38
|
-
mode: "mock",
|
|
39
|
-
provider: "mock"
|
|
40
|
-
}
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
function getSelectedProvider() {
|
|
44
|
-
var params = new URLSearchParams(window.location.search);
|
|
45
|
-
return params.get("ai") || defaultProvider;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
function mergeConfig() {
|
|
49
|
-
var selected = getSelectedProvider();
|
|
50
|
-
var providerConfig = providers[selected] || providers[defaultProvider];
|
|
51
|
-
return Object.assign({
|
|
52
|
-
selectedProvider: providers[selected] ? selected : defaultProvider
|
|
53
|
-
}, common, providerConfig);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
window.mapshaperAIConfigs = {
|
|
57
|
-
defaultProvider: defaultProvider,
|
|
58
|
-
common: common,
|
|
59
|
-
providers: providers
|
|
60
|
-
};
|
|
61
|
-
window.mapshaperAI = mergeConfig();
|
|
62
|
-
})();
|