@graview/pages 0.2.0 → 0.2.2
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/held-element.d.ts +12 -0
- package/dist/held-element.d.ts.map +1 -0
- package/dist/held-element.js +90 -0
- package/dist/held-element.js.map +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/one-place-city.d.ts.map +1 -1
- package/dist/one-place-city.js +1232 -193
- package/dist/one-place-city.js.map +1 -1
- package/dist/one-place-control.d.ts +9 -0
- package/dist/one-place-control.d.ts.map +1 -1
- package/dist/one-place-control.js +9 -0
- package/dist/one-place-control.js.map +1 -1
- package/dist/one-place-geometry.d.ts +72 -1
- package/dist/one-place-geometry.d.ts.map +1 -1
- package/dist/one-place-geometry.js +104 -6
- package/dist/one-place-geometry.js.map +1 -1
- package/dist/one-place-signs.d.ts +65 -0
- package/dist/one-place-signs.d.ts.map +1 -0
- package/dist/one-place-signs.js +405 -0
- package/dist/one-place-signs.js.map +1 -0
- package/dist/one-place.d.ts +12 -4
- package/dist/one-place.d.ts.map +1 -1
- package/dist/one-place.js +264 -54
- package/dist/one-place.js.map +1 -1
- package/dist/page-context.d.ts +19 -0
- package/dist/page-context.d.ts.map +1 -1
- package/dist/page-context.js.map +1 -1
- package/dist/page-problems.d.ts.map +1 -1
- package/dist/page-problems.js +18 -6
- package/dist/page-problems.js.map +1 -1
- package/dist/page-record.d.ts.map +1 -1
- package/dist/page-record.js +3 -1
- package/dist/page-record.js.map +1 -1
- package/dist/page-shell.d.ts.map +1 -1
- package/dist/page-shell.js +20 -4
- package/dist/page-shell.js.map +1 -1
- package/dist/page-typography.d.ts.map +1 -1
- package/dist/page-typography.js +3 -2
- package/dist/page-typography.js.map +1 -1
- package/dist/router.d.ts +2 -0
- package/dist/router.d.ts.map +1 -1
- package/dist/router.js +57 -5
- package/dist/router.js.map +1 -1
- package/package.json +6 -6
|
@@ -0,0 +1,405 @@
|
|
|
1
|
+
const overlap = (a, b) => Math.max(0, Math.min(a.x + a.width, b.x + b.width) - Math.max(a.x, b.x)) * Math.max(0, Math.min(a.y + a.height, b.y + b.height) - Math.max(a.y, b.y));
|
|
2
|
+
const grow = (box, by) => ({ x: box.x - by, y: box.y - by, width: box.width + 2 * by, height: box.height + 2 * by });
|
|
3
|
+
/** How far into a district's diamond a box reaches: above 1 is clear of it; the least of `|dx|/half-width + |dy|/half-height` over the box. */
|
|
4
|
+
export function diamondReach(box, tile) {
|
|
5
|
+
const cx = tile.x + tile.width / 2;
|
|
6
|
+
const cy = tile.y + tile.height / 2;
|
|
7
|
+
const nearest = (from, to, at) => Math.max(from, Math.min(to, at));
|
|
8
|
+
const dx = Math.abs(nearest(box.x, box.x + box.width, cx) - cx) / Math.max(1, tile.width / 2);
|
|
9
|
+
const dy = Math.abs(nearest(box.y, box.y + box.height, cy) - cy) / Math.max(1, tile.height / 2);
|
|
10
|
+
return dx + dy;
|
|
11
|
+
}
|
|
12
|
+
/** From one box to another, edge to edge: none where they meet. */
|
|
13
|
+
const boxGap = (a, b) => Math.hypot(Math.max(b.x - (a.x + a.width), 0, a.x - (b.x + b.width)), Math.max(b.y - (a.y + a.height), 0, a.y - (b.y + b.height)));
|
|
14
|
+
/** From a point to the nearest edge of a box: none inside it. */
|
|
15
|
+
const gapTo = (p, b) => Math.hypot(Math.max(b.x - p.x, 0, p.x - (b.x + b.width)), Math.max(b.y - p.y, 0, p.y - (b.y + b.height)));
|
|
16
|
+
/**
|
|
17
|
+
* What a pixel of a post across a board weighs, beside a pixel of a board on
|
|
18
|
+
* what it must never stand on (1 and more): a crossing the length of a card
|
|
19
|
+
* weighs less than one pixel of that, and more than any distance from where
|
|
20
|
+
* a board belongs.
|
|
21
|
+
*/
|
|
22
|
+
const POST_CROSSING = 1e-3;
|
|
23
|
+
export function placeSigns(asked) {
|
|
24
|
+
const { tiles, buildings, board } = asked;
|
|
25
|
+
const reserved = asked.reserved ?? [];
|
|
26
|
+
const words = asked.words ?? [];
|
|
27
|
+
const bounds = asked.bounds;
|
|
28
|
+
/** How much of a box the camera cannot show. */
|
|
29
|
+
const outside = (box) => (bounds ? box.width * box.height - overlap(box, bounds) : 0);
|
|
30
|
+
const names = new Map();
|
|
31
|
+
const feet = new Map();
|
|
32
|
+
const posts = new Map();
|
|
33
|
+
const scales = new Map();
|
|
34
|
+
const stood = [];
|
|
35
|
+
/** Each board's post as it stands: no other board stands across it. */
|
|
36
|
+
const stoodPosts = [];
|
|
37
|
+
const kinds = [...tiles.keys()];
|
|
38
|
+
const { width, height, post, gap } = board;
|
|
39
|
+
const card = (foot, scale = 1) => ({ x: foot.x - (width * scale) / 2, y: foot.y - height * scale, width: width * scale, height: height * scale });
|
|
40
|
+
const taken = (box, length) => ({ ...box, height: box.height + length });
|
|
41
|
+
/** A board's post, from its foot down, as wide as it is drawn. */
|
|
42
|
+
const postOf = (foot, length) => ({ x: foot.x - 1, y: foot.y, width: 2, height: Math.max(0, length) });
|
|
43
|
+
/** Each name as it stands: what a board weighs where the names stand first. */
|
|
44
|
+
let nameBoxes = [];
|
|
45
|
+
/** What a board's card and post would stand on, weighed: another board or a name most, then ground, then what is kept clear. */
|
|
46
|
+
// Past `bound` the sum is not finished: a place already worse than the best found is not weighed to the end.
|
|
47
|
+
const covers = (foot, length, ground, blocks, scale = 1, near, bound = Infinity) => {
|
|
48
|
+
const face = card(foot, scale);
|
|
49
|
+
const cardBox = grow(face, gap / 2);
|
|
50
|
+
const whole = taken(face, length);
|
|
51
|
+
const named = grow(whole, 2);
|
|
52
|
+
/*
|
|
53
|
+
* A POST NEVER CROSSES A BOARD (Nick's decision). Each board placed is
|
|
54
|
+
* an obstacle to the posts: this one's post down across a board already
|
|
55
|
+
* standing, or this card across a post already standing. It is weighed
|
|
56
|
+
* after what a board must never stand on — another board, a name, a
|
|
57
|
+
* district's ground — and before how far a board stands from where it
|
|
58
|
+
* belongs: of the places clear of those, one whose post crosses nothing
|
|
59
|
+
* is always taken. Where none is, the post is drawn under the board it
|
|
60
|
+
* crosses (`one-place.tsx`), never over its words.
|
|
61
|
+
*/
|
|
62
|
+
const pole = postOf(foot, length);
|
|
63
|
+
let crossed = 0;
|
|
64
|
+
for (const other of near?.stood ?? stood)
|
|
65
|
+
crossed += overlap(pole, other);
|
|
66
|
+
for (const other of near?.posts ?? stoodPosts)
|
|
67
|
+
crossed += overlap(cardBox, other);
|
|
68
|
+
let sum = crossed * POST_CROSSING;
|
|
69
|
+
for (const other of near?.stood ?? stood)
|
|
70
|
+
sum += overlap(cardBox, other) * 4;
|
|
71
|
+
for (const other of near?.names ?? nameBoxes)
|
|
72
|
+
sum += overlap(named, other) * 4;
|
|
73
|
+
if (sum > bound)
|
|
74
|
+
return sum;
|
|
75
|
+
// A district's ground is its diamond: the bare corners of its box are the street.
|
|
76
|
+
for (const other of ground) {
|
|
77
|
+
if (overlap(face, other) === 0)
|
|
78
|
+
continue;
|
|
79
|
+
const reach = diamondReach(face, other);
|
|
80
|
+
if (reach < 1)
|
|
81
|
+
sum += (1 - reach) * overlap(face, other) + 1;
|
|
82
|
+
}
|
|
83
|
+
if (sum > bound)
|
|
84
|
+
return sum;
|
|
85
|
+
for (const other of blocks)
|
|
86
|
+
sum += overlap(face, other);
|
|
87
|
+
for (const other of reserved)
|
|
88
|
+
sum += overlap(whole, other) * 2;
|
|
89
|
+
return sum + outside(whole) * 4;
|
|
90
|
+
};
|
|
91
|
+
const stand = (key, foot, length, scale = 1) => {
|
|
92
|
+
feet.set(key, foot);
|
|
93
|
+
posts.set(key, length);
|
|
94
|
+
if (scale !== 1)
|
|
95
|
+
scales.set(key, scale);
|
|
96
|
+
stood.push(grow(card(foot, scale), gap / 2));
|
|
97
|
+
stoodPosts.push(postOf(foot, length));
|
|
98
|
+
};
|
|
99
|
+
const allTiles = [...tiles.values()];
|
|
100
|
+
const placeNames = () => {
|
|
101
|
+
/*
|
|
102
|
+
* THE NAMES, LAST (or, asked, before the lists): beside the district, else under its front corner,
|
|
103
|
+
* and only where none of those is clear on the district's own ground —
|
|
104
|
+
* never over its buildings and their names, which are what Nearby is
|
|
105
|
+
* for: a name drawn as a card over its records hid them.
|
|
106
|
+
*/
|
|
107
|
+
const roofs = buildings.map((one) => ({ x: one.x - 4, y: one.y - 14, width: one.width + 8, height: one.height + 14 }));
|
|
108
|
+
// And never on a board, nor across the post it stands on: the views stood first, where they belong; a name has more places to go.
|
|
109
|
+
const signRooms = [...feet].flatMap(([key, foot]) => {
|
|
110
|
+
const face = card(foot, scales.get(key) ?? 1);
|
|
111
|
+
return [face, { x: foot.x - 3, y: foot.y, width: 6, height: posts.get(key) ?? post }];
|
|
112
|
+
});
|
|
113
|
+
const byFront = [...kinds].sort((a, b) => tiles.get(b).y + tiles.get(b).height - (tiles.get(a).y + tiles.get(a).height));
|
|
114
|
+
for (const kind of byFront) {
|
|
115
|
+
const size = asked.names.get(kind);
|
|
116
|
+
if (!size)
|
|
117
|
+
continue;
|
|
118
|
+
const tile = tiles.get(kind);
|
|
119
|
+
// A district the camera does not show says nothing: its name past the edge is a name cut off.
|
|
120
|
+
if (bounds && overlap(tile, bounds) < tile.width * tile.height * 0.15)
|
|
121
|
+
continue;
|
|
122
|
+
const cx = tile.x + tile.width / 2;
|
|
123
|
+
// Beside it first: the ground over its back and under its front is where its views and its front neighbor's stand.
|
|
124
|
+
const middle = [
|
|
125
|
+
{ x: tile.x + tile.width + 2, y: tile.y + tile.height / 2 - size.height / 2, ...size },
|
|
126
|
+
{ x: tile.x - size.width - 2, y: tile.y + tile.height / 2 - size.height / 2, ...size },
|
|
127
|
+
{ x: cx - size.width / 2, y: tile.y + tile.height + 2, ...size },
|
|
128
|
+
{ x: cx - size.width * 0.9, y: tile.y + tile.height + 2, ...size },
|
|
129
|
+
{ x: cx - size.width * 0.1, y: tile.y + tile.height + 2, ...size },
|
|
130
|
+
{ x: tile.x + tile.width + 2, y: tile.y + tile.height * 0.8 - size.height / 2, ...size },
|
|
131
|
+
{ x: tile.x - size.width - 2, y: tile.y + tile.height * 0.8 - size.height / 2, ...size },
|
|
132
|
+
{ x: cx - size.width / 2, y: tile.y + tile.height + size.height + 6, ...size },
|
|
133
|
+
{ x: tile.x + tile.width + 2, y: tile.y + tile.height / 2 - size.height * 1.5 - 2, ...size },
|
|
134
|
+
{ x: tile.x - size.width - 2, y: tile.y + tile.height / 2 - size.height * 1.5 - 2, ...size },
|
|
135
|
+
{ x: tile.x + tile.width + 2, y: tile.y + tile.height / 2 + size.height / 2 + 2, ...size },
|
|
136
|
+
{ x: tile.x - size.width - 2, y: tile.y + tile.height / 2 + size.height / 2 + 2, ...size },
|
|
137
|
+
{ x: cx - size.width / 2, y: tile.y + tile.height * 0.72 - size.height / 2, ...size },
|
|
138
|
+
{ x: cx - size.width / 2, y: tile.y + tile.height / 2 - size.height / 2, ...size },
|
|
139
|
+
];
|
|
140
|
+
/*
|
|
141
|
+
* At the edge of what is shown — a district half under the page beside
|
|
142
|
+
* the city — each slid along inside it, as far as it stays under its own
|
|
143
|
+
* district: the name whole, never cut by the edge.
|
|
144
|
+
*/
|
|
145
|
+
const inside = (box) => {
|
|
146
|
+
if (!bounds)
|
|
147
|
+
return box;
|
|
148
|
+
const least = Math.max(bounds.x, tile.x + 24 - box.width);
|
|
149
|
+
const most = Math.min(bounds.x + bounds.width - box.width, tile.x + tile.width - 24);
|
|
150
|
+
return least <= most ? { ...box, x: Math.max(least, Math.min(most, box.x)) } : box;
|
|
151
|
+
};
|
|
152
|
+
const tries = [...middle.map(inside), ...middle];
|
|
153
|
+
/*
|
|
154
|
+
* BESIDE ITS OWN DISTRICT OR NOWHERE (beside a page, `nameReach`): a
|
|
155
|
+
* name hundreds of pixels off, over another district, named the wrong
|
|
156
|
+
* one (Graview Cloud's Deep Time at 1280, "Plants" under the Tree of
|
|
157
|
+
* life's district). Where no clear place is that near, the district
|
|
158
|
+
* says no name here; its list's board and the bar still reach it.
|
|
159
|
+
*/
|
|
160
|
+
const nearEnough = (box) => asked.nameReach === undefined || boxGap(box, tile) <= asked.nameReach;
|
|
161
|
+
const cost = (box) => [...names.values(), ...words].reduce((sum, other) => sum + overlap(grow(box, 3), other) * 8, 0) +
|
|
162
|
+
reserved.reduce((sum, other) => sum + overlap(box, other), 0) +
|
|
163
|
+
outside(box) * 2 +
|
|
164
|
+
roofs.reduce((sum, roof) => sum + overlap(box, roof), 0) +
|
|
165
|
+
signRooms.reduce((sum, room) => sum + overlap(grow(box, 2), room) * 8, 0) +
|
|
166
|
+
kinds.reduce((sum, other) => sum + (other !== kind && diamondReach(box, tiles.get(other)) < 1 ? (1 - diamondReach(box, tiles.get(other))) * size.width * size.height : 0), 0);
|
|
167
|
+
let best = tries[0];
|
|
168
|
+
let least = Infinity;
|
|
169
|
+
for (const box of tries) {
|
|
170
|
+
if (!nearEnough(box))
|
|
171
|
+
continue;
|
|
172
|
+
const c = cost(box);
|
|
173
|
+
if (c < least - 0.5) {
|
|
174
|
+
least = c;
|
|
175
|
+
best = box;
|
|
176
|
+
}
|
|
177
|
+
if (c <= 0.5)
|
|
178
|
+
break;
|
|
179
|
+
}
|
|
180
|
+
/*
|
|
181
|
+
* Where every place by the district is taken (a small window's City,
|
|
182
|
+
* the lattice dense), the nearest clear place round it: a little further
|
|
183
|
+
* from its district, never over another name.
|
|
184
|
+
*/
|
|
185
|
+
if (least > 0.5) {
|
|
186
|
+
search: for (let ring = 1; ring <= 10; ring++) {
|
|
187
|
+
for (let row = -ring; row <= ring; row++) {
|
|
188
|
+
for (let col = -ring; col <= ring; col++) {
|
|
189
|
+
if (Math.max(Math.abs(row), Math.abs(col)) !== ring)
|
|
190
|
+
continue;
|
|
191
|
+
const box = { x: cx - size.width / 2 + (col * (size.width + 6)) / 2, y: tile.y + tile.height / 2 - size.height / 2 + row * (size.height + 4), ...size };
|
|
192
|
+
if (!nearEnough(box))
|
|
193
|
+
continue;
|
|
194
|
+
const c = cost(box);
|
|
195
|
+
if (c < least - 0.5) {
|
|
196
|
+
least = c;
|
|
197
|
+
best = box;
|
|
198
|
+
}
|
|
199
|
+
if (c <= 0.5)
|
|
200
|
+
break search;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
// Never past the edge of what is shown: kept inside it, as near its district as it can stand.
|
|
206
|
+
if (bounds && outside(best) > 0.5) {
|
|
207
|
+
best = { ...best, x: Math.max(bounds.x, Math.min(bounds.x + bounds.width - best.width, best.x)), y: Math.max(bounds.y, Math.min(bounds.y + bounds.height - best.height, best.y)) };
|
|
208
|
+
if (best.x > tile.x + tile.width || best.x + best.width < tile.x)
|
|
209
|
+
continue;
|
|
210
|
+
}
|
|
211
|
+
if (!nearEnough(best))
|
|
212
|
+
continue;
|
|
213
|
+
/*
|
|
214
|
+
* NEVER ON ANOTHER NAME, NOR A BOARD. A name and its problems are
|
|
215
|
+
* controls: one standing on another took the other's presses. Where
|
|
216
|
+
* every place by its district is taken (a small window beside a page),
|
|
217
|
+
* the nearest place clear of them both, inside what is shown, on a
|
|
218
|
+
* district's ground if it must be; with none, the district says no name
|
|
219
|
+
* here rather than one over another.
|
|
220
|
+
*/
|
|
221
|
+
const onAnother = (box) => [...names.values(), ...words].some((other) => overlap(grow(box, 2), other) > 0.5) || signRooms.some((room) => overlap(grow(box, 2), room) > 0.5);
|
|
222
|
+
if (onAnother(best)) {
|
|
223
|
+
let clear = null;
|
|
224
|
+
let leastClear = Infinity;
|
|
225
|
+
for (let ring = 1; ring <= 10 && !clear; ring++) {
|
|
226
|
+
for (let row = -ring; row <= ring; row++) {
|
|
227
|
+
for (let col = -ring; col <= ring; col++) {
|
|
228
|
+
if (Math.max(Math.abs(row), Math.abs(col)) !== ring)
|
|
229
|
+
continue;
|
|
230
|
+
const box = { x: best.x + (col * (size.width + 6)) / 3, y: best.y + row * (size.height + 4), ...size };
|
|
231
|
+
if ((bounds && outside(box) > 0.5) || onAnother(box) || !nearEnough(box))
|
|
232
|
+
continue;
|
|
233
|
+
const c = cost(box);
|
|
234
|
+
if (c < leastClear) {
|
|
235
|
+
leastClear = c;
|
|
236
|
+
clear = box;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
if (!clear)
|
|
242
|
+
continue;
|
|
243
|
+
best = clear;
|
|
244
|
+
}
|
|
245
|
+
// Kept beside its district, a name never stands over records instead: with nothing clear that near, none.
|
|
246
|
+
if (asked.nameReach !== undefined && roofs.some((roof) => overlap(best, roof) > 0.5))
|
|
247
|
+
continue;
|
|
248
|
+
names.set(kind, best);
|
|
249
|
+
}
|
|
250
|
+
nameBoxes = [...names.values()];
|
|
251
|
+
};
|
|
252
|
+
/* THE PAGE BEING READ, ON ITS BUILDING: straight over it, on the shortest post that stands its card clear — never to one side, where its post would come down on another building. */
|
|
253
|
+
for (const sign of asked.signs) {
|
|
254
|
+
if (!sign.building)
|
|
255
|
+
continue;
|
|
256
|
+
const roof = { x: sign.building.x + sign.building.width / 2, y: sign.building.y };
|
|
257
|
+
const own = sign.kind ? tiles.get(sign.kind) : undefined;
|
|
258
|
+
const ground = allTiles.filter((tile) => tile !== own);
|
|
259
|
+
let best = null;
|
|
260
|
+
for (let raise = 0; raise <= 12; raise++) {
|
|
261
|
+
const length = post + raise * (height / 3);
|
|
262
|
+
const foot = { x: roof.x, y: roof.y - length };
|
|
263
|
+
const cost = covers(foot, length, [...ground, ...(own ? [own] : [])], buildings) + raise * 2;
|
|
264
|
+
if (!best || cost < best.cost)
|
|
265
|
+
best = { foot, length, cost };
|
|
266
|
+
if (best && best.cost <= raise * 2 + 0.5 && covers(best.foot, best.length, [...ground, ...(own ? [own] : [])], buildings) <= 0.5)
|
|
267
|
+
break;
|
|
268
|
+
}
|
|
269
|
+
if (best)
|
|
270
|
+
stand(sign.key, best.foot, best.length);
|
|
271
|
+
}
|
|
272
|
+
/* THE PLAZA, AND EACH KIND'S VIEWS: the nearest clear place to where they belong. */
|
|
273
|
+
const city = allTiles.length > 0 ? allTiles.reduce((a, b) => ({ x: Math.min(a.x, b.x), y: Math.min(a.y, b.y), width: Math.max(a.x + a.width, b.x + b.width) - Math.min(a.x, b.x), height: Math.max(a.y + a.height, b.y + b.height) - Math.min(a.y, b.y) })) : null;
|
|
274
|
+
const stepX = width + gap;
|
|
275
|
+
const stepY = height + post + gap;
|
|
276
|
+
/* The places a board may stand round where it is wanted, nearest first: the first clear one is taken, and only where none is, the one that covers least. */
|
|
277
|
+
const around = [];
|
|
278
|
+
for (let row = -10; row <= 10; row++)
|
|
279
|
+
for (let col = -14; col <= 14; col++)
|
|
280
|
+
around.push({ col, row, far: Math.hypot((col * stepX) / 2, ((row * stepY) / 2) * 1.2) });
|
|
281
|
+
around.sort((a, b) => a.far - b.far);
|
|
282
|
+
/** A district the camera shows enough of to stand anything by: one past the edge says nothing, and its views stand where it is seen. */
|
|
283
|
+
const inSight = (box) => !bounds || overlap(box, bounds) >= box.width * box.height * 0.15;
|
|
284
|
+
const standNear = (key, kind, want) => {
|
|
285
|
+
const own = kind ? tiles.get(kind) : undefined;
|
|
286
|
+
// Where it belongs is out of sight (a district past the window at Nearby, the plaza behind it): it stands where that is seen, not shoved into view over something else.
|
|
287
|
+
if (own ? !inSight(own) : bounds && !inSight({ x: want.x - width / 2, y: want.y - height, width, height }))
|
|
288
|
+
return;
|
|
289
|
+
let best = null;
|
|
290
|
+
for (const { col, row, far } of around) {
|
|
291
|
+
if (asked.dropCovered && best && best.cost < 1e6)
|
|
292
|
+
break;
|
|
293
|
+
if (best && far >= best.cost)
|
|
294
|
+
break;
|
|
295
|
+
const foot = { x: want.x + (col * stepX) / 2, y: want.y + (row * stepY) / 2 };
|
|
296
|
+
// A view stands on its own district: a foot nearer another district's ground than its own reads as that one's — worse than far, never as bad as on top of something.
|
|
297
|
+
const mine = own ? gapTo(foot, own) : 0;
|
|
298
|
+
const astray = own !== undefined && kinds.some((other) => other !== kind && gapTo(foot, tiles.get(other)) <= mine);
|
|
299
|
+
const cost = (astray ? 1e5 : 0) + far;
|
|
300
|
+
if (best && cost >= best.cost)
|
|
301
|
+
continue;
|
|
302
|
+
const covered = covers(foot, post, allTiles, buildings) * 1e6 + cost;
|
|
303
|
+
if (!best || covered < best.cost)
|
|
304
|
+
best = { foot, cost: covered };
|
|
305
|
+
}
|
|
306
|
+
if (best && !(asked.dropCovered && best.cost >= 1e6))
|
|
307
|
+
stand(key, best.foot, post);
|
|
308
|
+
};
|
|
309
|
+
/*
|
|
310
|
+
* A KIND'S VIEWS STAND ON ITS DISTRICT: each card over the district's
|
|
311
|
+
* back, its post coming down onto the district's own ground — never
|
|
312
|
+
* beside a neighbor, never in a column off to the side, where its post
|
|
313
|
+
* pointed at bare ground. The shortest post first and nearest the
|
|
314
|
+
* district's middle; where the room over it is short, a little to one
|
|
315
|
+
* side, then drawn a little smaller; and only where nothing there is
|
|
316
|
+
* clear, the place that covers least — or, asked (a phone), none.
|
|
317
|
+
*/
|
|
318
|
+
const tries = [];
|
|
319
|
+
// Smaller, as far as its words are still read, before a board with no clear place stands nowhere.
|
|
320
|
+
const smaller = asked.shrink === false ? [1] : [1, 0.85, 0.7, 0.6, 0.5, 0.42, 0.35].filter((scale) => scale === 1 || (asked.least !== undefined ? scale >= 0.5 && width * scale >= asked.least : scale >= 0.7));
|
|
321
|
+
for (const scale of smaller)
|
|
322
|
+
for (let raise = 0; raise <= (asked.reach ?? 12); raise++)
|
|
323
|
+
for (const side of [0, -0.3, 0.3, -0.55, 0.55, -0.8, 0.8])
|
|
324
|
+
tries.push({ scale, raise, side, prefer: raise * 10 + Math.abs(side) * 30 + (1 - scale) * 120 });
|
|
325
|
+
tries.sort((a, b) => a.prefer - b.prefer);
|
|
326
|
+
const standOn = (key, kind) => {
|
|
327
|
+
// A district with many views stops looking long before it has tried every place for the last of them.
|
|
328
|
+
const cap = (ofKind(kind).length > 6 ? 48 : Infinity);
|
|
329
|
+
const tile = tiles.get(kind);
|
|
330
|
+
// A district any of which is seen keeps its views' boards: they stand where it is seen.
|
|
331
|
+
if (bounds && overlap(tile, bounds) < tile.width * tile.height * 0.05)
|
|
332
|
+
return;
|
|
333
|
+
const half = { w: tile.width / 2, h: tile.height / 2 };
|
|
334
|
+
const middleX = tile.x + half.w;
|
|
335
|
+
const middleY = tile.y + half.h;
|
|
336
|
+
const roofs = buildings.filter((one) => one.x + one.width / 2 > tile.x && one.x + one.width / 2 < tile.x + tile.width && one.y + one.height > tile.y && one.y + one.height < tile.y + tile.height);
|
|
337
|
+
const top = Math.min(tile.y, ...roofs.map((one) => one.y)) - 2;
|
|
338
|
+
// Only what stands near enough to be stood on is weighed: the search stays as cheap with a thousand buildings as with ten.
|
|
339
|
+
// The cards stand over the district's back, at most four of their heights up and a little to either side: what can stand there is all that is weighed.
|
|
340
|
+
const reachX = half.w * 0.55 + width / 2 + gap;
|
|
341
|
+
const up = ((asked.reach ?? 12) / 2 + 1) * height;
|
|
342
|
+
const region = { x: middleX - reachX - half.w * 0.25, y: top - gap - up, width: 2 * reachX + half.w * 0.5, height: middleY - (top - gap - up) };
|
|
343
|
+
const groundNear = allTiles.filter((one) => overlap(one, region) > 0);
|
|
344
|
+
const blocksNear = buildings.filter((one) => overlap(one, region) > 0);
|
|
345
|
+
const near = { stood: stood.filter((one) => overlap(one, region) > 0), posts: stoodPosts.filter((one) => overlap(one, region) > 0), names: nameBoxes.filter((one) => overlap(one, region) > 0) };
|
|
346
|
+
let best = null;
|
|
347
|
+
// The places tried, the least to ask first, and no more than so many: a district with sixty views stops looking long before it has tried every place for the sixtieth.
|
|
348
|
+
let tried = 0;
|
|
349
|
+
for (const { scale, raise, side, prefer } of tries) {
|
|
350
|
+
if (best && prefer >= best.cost)
|
|
351
|
+
break;
|
|
352
|
+
if (++tried > cap && best)
|
|
353
|
+
break;
|
|
354
|
+
// Where the post meets the ground: on the district's back half, inside its diamond.
|
|
355
|
+
const ground = { x: middleX + side * half.w, y: middleY - half.h * (1 - Math.abs(side)) * 0.6 };
|
|
356
|
+
const foot = { x: ground.x, y: top - gap - raise * ((height * scale) / 2) };
|
|
357
|
+
const length = ground.y - foot.y;
|
|
358
|
+
const bound = best ? (best.cost - prefer) / 1e6 : Infinity;
|
|
359
|
+
const cost = covers(foot, length, groundNear, blocksNear, scale, near, bound) * 1e6 + prefer;
|
|
360
|
+
if (!best || cost < best.cost)
|
|
361
|
+
best = { foot, length, scale, cost };
|
|
362
|
+
}
|
|
363
|
+
if (!best || (asked.dropCovered && best.cost >= 1e6))
|
|
364
|
+
return;
|
|
365
|
+
stand(key, best.foot, best.length, best.scale);
|
|
366
|
+
};
|
|
367
|
+
// A kind's views first, the kinds with most of them first: they have one district to stand on, the plaza's have the whole back edge.
|
|
368
|
+
const ofKind = (kind) => asked.signs.filter((one) => !one.building && one.kind === kind);
|
|
369
|
+
/*
|
|
370
|
+
* THE BOARDS ASKED FIRST STAND FIRST (beside a page, the app's views
|
|
371
|
+
* before the kinds' own lists): where the city's side is narrow, a
|
|
372
|
+
* district's view is not left without room by a neighbor's list board
|
|
373
|
+
* climbing over it. The district with least room over its back — the
|
|
374
|
+
* nearest the top of what is shown — first: its neighbors in front have
|
|
375
|
+
* room to stand higher, it has none.
|
|
376
|
+
*/
|
|
377
|
+
const firsts = asked.signs.filter((one) => one.first && !one.building && one.kind !== null && tiles.has(one.kind));
|
|
378
|
+
const roomOver = (kind) => tiles.get(kind).y - (bounds?.y ?? 0);
|
|
379
|
+
for (const sign of [...firsts].sort((a, b) => roomOver(a.kind) - roomOver(b.kind)))
|
|
380
|
+
standOn(sign.key, sign.kind);
|
|
381
|
+
/*
|
|
382
|
+
* THE NAMES BEFORE THE LISTS (beside a page, where the city's side is
|
|
383
|
+
* narrow): each beside its own district, right after the views, and the
|
|
384
|
+
* kinds' list boards weighed against them. Placed after every board, a
|
|
385
|
+
* district at the back found every place by it taken, and its name went
|
|
386
|
+
* hundreds of pixels off over another district.
|
|
387
|
+
*/
|
|
388
|
+
if (asked.namesFirst)
|
|
389
|
+
placeNames();
|
|
390
|
+
for (const kind of [...kinds].sort((a, b) => ofKind(b).length - ofKind(a).length)) {
|
|
391
|
+
for (const sign of ofKind(kind))
|
|
392
|
+
if (!sign.first)
|
|
393
|
+
standOn(sign.key, kind);
|
|
394
|
+
}
|
|
395
|
+
const plaza = asked.plaza === false ? [] : asked.signs.filter((sign) => !sign.building && (sign.kind === null || !tiles.has(sign.kind)));
|
|
396
|
+
if (city) {
|
|
397
|
+
plaza.forEach((sign, index) => standNear(sign.key, null, { x: city.x + city.width / 2 + (index - (plaza.length - 1) / 2) * stepX, y: city.y - post - 6 }));
|
|
398
|
+
}
|
|
399
|
+
if (!asked.namesFirst)
|
|
400
|
+
placeNames();
|
|
401
|
+
const boxes = [...allTiles, ...names.values(), ...[...feet].map(([key, foot]) => taken(card(foot, scales.get(key) ?? 1), posts.get(key) ?? post))];
|
|
402
|
+
const whole = boxes.length === 0 ? null : boxes.reduce((a, b) => ({ x: Math.min(a.x, b.x), y: Math.min(a.y, b.y), width: Math.max(a.x + a.width, b.x + b.width) - Math.min(a.x, b.x), height: Math.max(a.y + a.height, b.y + b.height) - Math.min(a.y, b.y) }));
|
|
403
|
+
return { feet, posts, scales, names, whole };
|
|
404
|
+
}
|
|
405
|
+
//# sourceMappingURL=one-place-signs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"one-place-signs.js","sourceRoot":"","sources":["../src/one-place-signs.ts"],"names":[],"mappings":"AAqFA,MAAM,OAAO,GAAG,CAAC,CAAM,EAAE,CAAM,EAAU,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CA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AC,IAAI,CAAC,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC;IAC1J,MAAM,KAAK,GAAG,KAAK,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAChQ,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC;AAC/C,CAAC"}
|
package/dist/one-place.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type AnySchema } from "@graview/core";
|
|
2
2
|
import { type ReactNode, type RefObject } from "react";
|
|
3
3
|
import { type PageContext } from "./page-context.js";
|
|
4
|
+
import { type OneFace } from "./one-place-control.js";
|
|
4
5
|
import { PHONE, type PageWhere } from "./one-place-geometry.js";
|
|
5
6
|
/** What the frame asks the camera for, read by the city part each frame. */
|
|
6
7
|
export interface Motion {
|
|
@@ -21,10 +22,11 @@ export interface Board {
|
|
|
21
22
|
readonly label: string;
|
|
22
23
|
/** Its path on this face. */
|
|
23
24
|
readonly path: string;
|
|
24
|
-
/** What it is, said over its title: the home, a list, a view, a record. */
|
|
25
25
|
/** What it is, said to a screen reader: the home, a list, a view, a record's page. */
|
|
26
26
|
readonly eyebrow: string;
|
|
27
|
-
/** What it
|
|
27
|
+
/** What it is, drawn over its title: "90 species", "View · species", "Front page". */
|
|
28
|
+
readonly says: string;
|
|
29
|
+
/** What a list shows, live: the first few of its records' names, drawn on its sign. A view draws its own picture, so says none of them. */
|
|
28
30
|
readonly lines: readonly string[];
|
|
29
31
|
readonly kind?: string | undefined;
|
|
30
32
|
readonly where: PageWhere;
|
|
@@ -52,6 +54,7 @@ export interface OnePlaceCityProps {
|
|
|
52
54
|
readonly height: number;
|
|
53
55
|
readonly top: number;
|
|
54
56
|
readonly panel?: number;
|
|
57
|
+
readonly share?: number;
|
|
55
58
|
};
|
|
56
59
|
readonly lessMotion: boolean;
|
|
57
60
|
/** What an address on the page is: a record, a kind's list, or nothing of the city's. */
|
|
@@ -71,9 +74,14 @@ export interface OnePlaceCityProps {
|
|
|
71
74
|
readonly moving: boolean;
|
|
72
75
|
}) => void;
|
|
73
76
|
}
|
|
74
|
-
export declare function OnePlace<S extends AnySchema>({ context, children }: {
|
|
77
|
+
export declare function OnePlace<S extends AnySchema>({ context, page, onFace, children, }: {
|
|
75
78
|
readonly context: PageContext<S>;
|
|
76
|
-
|
|
79
|
+
/** The routed page, drawn once into this element before the face arrived: moved into the sheet, never drawn again (`router.tsx`). */
|
|
80
|
+
readonly page?: HTMLElement | null | undefined;
|
|
81
|
+
/** Told the face once it is here, and null once it goes: the page, drawn where it was first drawn, reads the face through it. */
|
|
82
|
+
readonly onFace?: ((face: OneFace | null) => void) | undefined;
|
|
83
|
+
/** The page, where it is drawn here (a server's drawing, where nothing moves). */
|
|
84
|
+
readonly children?: ReactNode;
|
|
77
85
|
}): import("react").JSX.Element;
|
|
78
86
|
export { PHONE };
|
|
79
87
|
//# sourceMappingURL=one-place.d.ts.map
|
package/dist/one-place.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"one-place.d.ts","sourceRoot":"","sources":["../src/one-place.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"one-place.d.ts","sourceRoot":"","sources":["../src/one-place.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA0E,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AAKvH,OAAO,EAAiO,KAAK,SAAS,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAGtR,OAAO,EAAgB,KAAK,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAGnE,OAAO,EAAkB,KAAK,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAEtE,OAAO,EAAgJ,KAAK,EAAY,KAAK,SAAS,EAAa,MAAM,yBAAyB,CAAC;AAuCnO,4EAA4E;AAC5E,MAAM,WAAW,MAAM;IACrB,8EAA8E;IAC9E,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,iFAAiF;IACjF,KAAK,EAAE,MAAM,CAAC;IACd,iDAAiD;IACjD,SAAS,EAAE,OAAO,CAAC;IACnB,4DAA4D;IAC5D,IAAI,EAAE,OAAO,CAAC;IACd,uGAAuG;IACvG,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,2EAA2E;AAC3E,MAAM,WAAW,KAAK;IACpB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,6BAA6B;IAC7B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,sFAAsF;IACtF,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,sFAAsF;IACtF,QAAQ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