@gramps-connect/story 0.3.0 → 0.4.0
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/README.md +14 -5
- package/dist/editor.js +464 -165
- package/dist/editor.js.map +4 -4
- package/dist/types/editor/PlaceField.d.ts +21 -0
- package/dist/types/editor/PlaceMap.d.ts +12 -0
- package/dist/types/editor/StoryEditor.d.ts +5 -1
- package/dist/types/editor/index.d.ts +3 -1
- package/dist/types/editor/model.d.ts +17 -1
- package/dist/types/editor/placeSearch.d.ts +22 -0
- package/dist/types/editor/strings.d.ts +15 -0
- package/package.json +1 -1
- package/src/editor/PlaceField.tsx +160 -0
- package/src/editor/PlaceMap.tsx +88 -0
- package/src/editor/StoryEditor.tsx +27 -14
- package/src/editor/index.ts +5 -2
- package/src/editor/model.ts +38 -1
- package/src/editor/placeSearch.ts +61 -0
- package/src/editor/strings.ts +30 -0
package/src/editor/strings.ts
CHANGED
|
@@ -32,6 +32,21 @@ export interface EditorStrings {
|
|
|
32
32
|
matchDateAsWritten: string;
|
|
33
33
|
noPreciseDate: string;
|
|
34
34
|
place: string;
|
|
35
|
+
placeName: string;
|
|
36
|
+
removePlace: string;
|
|
37
|
+
findPlace: string;
|
|
38
|
+
findPlaceHint: string;
|
|
39
|
+
findPlaceNone: string;
|
|
40
|
+
findPlaceFailed: string;
|
|
41
|
+
findPlaceNoPoint: (name: string) => string;
|
|
42
|
+
coordinates: string;
|
|
43
|
+
coordinatesHint: string;
|
|
44
|
+
coordinatesInvalid: string;
|
|
45
|
+
placeMap: string;
|
|
46
|
+
placeMapHint: string;
|
|
47
|
+
placeShape: string;
|
|
48
|
+
placeOverlays: (count: number) => string;
|
|
49
|
+
placeKeeps: (what: string) => string;
|
|
35
50
|
photos: string;
|
|
36
51
|
photosHint: string;
|
|
37
52
|
addPhoto: string;
|
|
@@ -84,6 +99,21 @@ export const EDITOR_ENGLISH: EditorStrings = {
|
|
|
84
99
|
matchDateAsWritten: "Work it out from the date",
|
|
85
100
|
noPreciseDate: "None: this slide stays off the timeline.",
|
|
86
101
|
place: "Place",
|
|
102
|
+
placeName: "Name",
|
|
103
|
+
removePlace: "Remove place",
|
|
104
|
+
findPlace: "Find on Wikidata",
|
|
105
|
+
findPlaceHint: "Looks the name up on Wikidata, to put the pin there. The name is all that's sent, and only when you ask.",
|
|
106
|
+
findPlaceNone: "Wikidata has no place by that name.",
|
|
107
|
+
findPlaceFailed: "Couldn't reach Wikidata.",
|
|
108
|
+
findPlaceNoPoint: (name) => `Wikidata has no map position for ${name}.`,
|
|
109
|
+
coordinates: "Latitude, longitude",
|
|
110
|
+
coordinatesHint: "e.g. 47.3769, 8.5417",
|
|
111
|
+
coordinatesInvalid: "Two numbers: latitude (-90 to 90), then longitude (-180 to 180).",
|
|
112
|
+
placeMap: "Map: click to put the pin",
|
|
113
|
+
placeMapHint: "Click the map to put the pin there, or drag the pin.",
|
|
114
|
+
placeShape: "a shape",
|
|
115
|
+
placeOverlays: (count) => (count === 1 ? "a map overlay" : `${count} map overlays`),
|
|
116
|
+
placeKeeps: (what) => `This place also has ${what}, kept as they are.`,
|
|
87
117
|
photos: "Photos",
|
|
88
118
|
photosHint: "Add, drop or paste a photo. It's resized for the screen, and hidden details like camera and location are left out.",
|
|
89
119
|
addPhoto: "Add photo",
|