utopia-ui 3.0.0-alpha.49 → 3.0.0-alpha.50
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.js +15 -15
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
@@ -2304,18 +2304,18 @@ var SearchControl = function (_a) {
|
|
2304
2304
|
Array.from(geoResults).length > 0 && (itemsResults.length > 0 || tagsResults.length > 0) && React.createElement("hr", { className: 'tw-opacity-50' }),
|
2305
2305
|
Array.from(geoResults).map(function (geo) {
|
2306
2306
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
2307
|
-
return (React.createElement("div", { className: 'tw-flex tw-flex-row', key: Math.random()
|
2307
|
+
return (React.createElement("div", { className: 'tw-flex tw-flex-row hover:tw-font-bold tw-cursor-pointer', key: Math.random(), onClick: function () {
|
2308
|
+
var _a, _b;
|
2309
|
+
(_a = searchInput.current) === null || _a === void 0 ? void 0 : _a.blur();
|
2310
|
+
L$1.marker(new LatLng(geo.geometry.coordinates[1], geo.geometry.coordinates[0]), { icon: MarkerIconFactory("circle", "#777", "RGBA(35, 31, 32, 0.2)", "circle-solid") }).addTo(map).bindPopup("<h3 class=\"tw-text-base tw-font-bold\">".concat((geo === null || geo === void 0 ? void 0 : geo.properties.name) ? geo === null || geo === void 0 ? void 0 : geo.properties.name : value, "<h3>").concat(capitalizeFirstLetter$1((_b = geo === null || geo === void 0 ? void 0 : geo.properties) === null || _b === void 0 ? void 0 : _b.osm_value))).openPopup().addEventListener("popupclose", function (e) { console.log(e.target.remove()); });
|
2311
|
+
if (geo.properties.extent)
|
2312
|
+
map.fitBounds(new LatLngBounds(new LatLng(geo.properties.extent[1], geo.properties.extent[0]), new LatLng(geo.properties.extent[3], geo.properties.extent[2])));
|
2313
|
+
else
|
2314
|
+
map.setView(new LatLng(geo.geometry.coordinates[1], geo.geometry.coordinates[0]), 15, { duration: 1 });
|
2315
|
+
} },
|
2308
2316
|
React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: "1.5", stroke: "currentColor", className: "tw-text-current tw-mr-2 tw-mt-0 tw-w-4" },
|
2309
2317
|
React.createElement("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z" })),
|
2310
|
-
React.createElement("div",
|
2311
|
-
var _a, _b;
|
2312
|
-
(_a = searchInput.current) === null || _a === void 0 ? void 0 : _a.blur();
|
2313
|
-
L$1.marker(new LatLng(geo.geometry.coordinates[1], geo.geometry.coordinates[0]), { icon: MarkerIconFactory("circle", "#777", "RGBA(35, 31, 32, 0.2)", "circle-solid") }).addTo(map).bindPopup("<h3 class=\"tw-text-base tw-font-bold\">".concat(value, "<h3>").concat(capitalizeFirstLetter$1((_b = geo === null || geo === void 0 ? void 0 : geo.properties) === null || _b === void 0 ? void 0 : _b.osm_value))).openPopup().addEventListener("popupclose", function (e) { console.log(e.target.remove()); });
|
2314
|
-
if (geo.properties.extent)
|
2315
|
-
map.fitBounds(new LatLngBounds(new LatLng(geo.properties.extent[1], geo.properties.extent[0]), new LatLng(geo.properties.extent[3], geo.properties.extent[2])));
|
2316
|
-
else
|
2317
|
-
map.setView(new LatLng(geo.geometry.coordinates[1], geo.geometry.coordinates[0]), 15, { duration: 1 });
|
2318
|
-
} },
|
2318
|
+
React.createElement("div", null,
|
2319
2319
|
React.createElement("div", { className: 'tw-text-sm tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap tw-max-w-[17rem]' }, (geo === null || geo === void 0 ? void 0 : geo.properties.name) ? geo === null || geo === void 0 ? void 0 : geo.properties.name : value),
|
2320
2320
|
React.createElement("div", { className: 'tw-text-xs tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap tw-max-w-[17rem]' },
|
2321
2321
|
((_a = geo === null || geo === void 0 ? void 0 : geo.properties) === null || _a === void 0 ? void 0 : _a.city) && "".concat(capitalizeFirstLetter$1((_b = geo === null || geo === void 0 ? void 0 : geo.properties) === null || _b === void 0 ? void 0 : _b.city), ", "),
|
@@ -2327,13 +2327,13 @@ var SearchControl = function (_a) {
|
|
2327
2327
|
geo.properties.country && geo.properties.country))));
|
2328
2328
|
}),
|
2329
2329
|
isGeoCoordinate(value) &&
|
2330
|
-
React.createElement("div", { className: 'tw-flex tw-flex-row'
|
2330
|
+
React.createElement("div", { className: 'tw-flex tw-flex-row hover:tw-font-bold tw-cursor-pointer', onClick: function () {
|
2331
|
+
L$1.marker(new LatLng(extractCoordinates(value)[0], extractCoordinates(value)[1]), { icon: MarkerIconFactory("circle", "#777", "RGBA(35, 31, 32, 0.2)", "circle-solid") }).addTo(map).bindPopup("<h3 class=\"tw-text-base tw-font-bold\">".concat(extractCoordinates(value)[0], ", ").concat(extractCoordinates(value)[1], "</h3>")).openPopup().addEventListener("popupclose", function (e) { console.log(e.target.remove()); });
|
2332
|
+
map.setView(new LatLng(extractCoordinates(value)[0], extractCoordinates(value)[1]), 15, { duration: 1 });
|
2333
|
+
} },
|
2331
2334
|
React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "currentColor", className: "tw-text-current tw-mr-2 tw-mt-0 tw-w-4" },
|
2332
2335
|
React.createElement("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M3 3v1.5M3 21v-6m0 0 2.77-.693a9 9 0 0 1 6.208.682l.108.054a9 9 0 0 0 6.086.71l3.114-.732a48.524 48.524 0 0 1-.005-10.499l-3.11.732a9 9 0 0 1-6.085-.711l-.108-.054a9 9 0 0 0-6.208-.682L3 4.5M3 15V4.5" })),
|
2333
|
-
React.createElement("div",
|
2334
|
-
L$1.marker(new LatLng(extractCoordinates(value)[0], extractCoordinates(value)[1]), { icon: MarkerIconFactory("circle", "#777", "RGBA(35, 31, 32, 0.2)", "circle-solid") }).addTo(map).bindPopup("<h3 class=\"tw-text-base tw-font-bold\">".concat(extractCoordinates(value)[0], ", ").concat(extractCoordinates(value)[1], "</h3>")).openPopup().addEventListener("popupclose", function (e) { console.log(e.target.remove()); });
|
2335
|
-
map.setView(new LatLng(extractCoordinates(value)[0], extractCoordinates(value)[1]), 15, { duration: 1 });
|
2336
|
-
} },
|
2336
|
+
React.createElement("div", null,
|
2337
2337
|
React.createElement("div", { className: 'tw-text-sm tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap tw-max-w-[17rem]' }, value),
|
2338
2338
|
React.createElement("div", { className: 'tw-text-xs tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap tw-max-w-[17rem]' }, "Coordiante")))))));
|
2339
2339
|
};
|