utopia-ui 3.0.0-alpha.115 → 3.0.0-alpha.117

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 CHANGED
@@ -3258,7 +3258,7 @@ var TextView = function (_a) {
3258
3258
  };
3259
3259
  var CustomExternalLink = function (_a) {
3260
3260
  var href = _a.href, children = _a.children;
3261
- return (jsxs("a", __assign({ className: 'tw-font-bold', href: href, target: "_blank" }, { children: [" ", children] })));
3261
+ return (jsxs("a", __assign({ className: 'tw-font-bold', href: href }, { children: [" ", children] })));
3262
3262
  };
3263
3263
  var CustomHashTagLink = function (_a) {
3264
3264
  var children = _a.children, tag = _a.tag, item = _a.item;
@@ -3407,7 +3407,7 @@ var ItemViewPopup = React.forwardRef(function (props, ref) {
3407
3407
  }
3408
3408
  });
3409
3409
  }); };
3410
- return (jsx(Popup, __assign({ ref: ref, maxHeight: 377, minWidth: 275, maxWidth: 275, autoPanPadding: [20, 80] }, { children: jsxs("div", __assign({ className: 'tw-bg-base-100 tw-text-base-content' }, { children: [jsx(HeaderView, { api: (_a = props.item.layer) === null || _a === void 0 ? void 0 : _a.api, item: props.item, editCallback: handleEdit, deleteCallback: handleDelete, setPositionCallback: function () { map.closePopup(); setSelectPosition(props.item); navigate("/"); }, loading: loading, hideSubname: true }), jsx("div", __assign({ className: 'tw-overflow-y-auto tw-overflow-x-hidden tw-max-h-64 fade' }, { children: props.children ?
3410
+ return (jsx(Popup, __assign({ ref: ref, maxHeight: 377, minWidth: 275, maxWidth: 275, autoPanPadding: [20, 80] }, { children: jsxs("div", __assign({ className: 'tw-bg-base-100 tw-text-base-content' }, { children: [jsx(HeaderView, { api: (_a = props.item.layer) === null || _a === void 0 ? void 0 : _a.api, item: props.item, editCallback: handleEdit, deleteCallback: handleDelete, setPositionCallback: function () { map.closePopup(); setSelectPosition(props.item); navigate("/"); }, loading: loading }), jsx("div", __assign({ className: 'tw-overflow-y-auto tw-overflow-x-hidden tw-max-h-64 fade' }, { children: props.children ?
3411
3411
  React.Children.toArray(props.children).map(function (child) {
3412
3412
  return React.isValidElement(child) ?
3413
3413
  React.cloneElement(child, { item: props.item }) : "";
@@ -4955,8 +4955,10 @@ function Quests() {
4955
4955
  useEffect(function () {
4956
4956
  setQuestsOpen(false);
4957
4957
  }, []);
4958
+ var items = useItems();
4959
+ var profile = items.find(function (i) { return i.user_created.id === (user === null || user === void 0 ? void 0 : user.id) && i.type == "user"; });
4958
4960
  return (jsx(Fragment, { children: questsOpen ?
4959
- jsx("div", __assign({ className: "tw-card tw-w-48 tw-bg-base-100 tw-shadow-xl tw-absolute tw-bottom-4 tw-left-4 tw-z-[2000]" }, { children: jsxs("div", __assign({ className: "tw-card-body tw-p-4 tw-pt-0" }, { children: [jsx("div", __assign({ className: "tw-card-actions tw-justify-end" }, { children: jsx("label", __assign({ className: "tw-btn tw-btn-sm tw-btn-circle tw-btn-ghost tw-absolute tw-right-1 tw-top-1", onClick: function () { return setQuestsOpen(false); } }, { children: "\u2715" })) })), jsxs("h2", __assign({ className: "tw-card-title tw-m-auto " }, { children: ["Level 1", jsx("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "#aaa", className: "tw-w-5 tw-h-5 tw-cursor-pointer" }, { children: jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M9.879 7.519c1.171-1.025 3.071-1.025 4.242 0 1.172 1.025 1.172 2.687 0 3.712-.203.179-.43.326-.67.442-.745.361-1.45.999-1.45 1.827v.75M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9 5.25h.008v.008H12v-.008z" }) }))] })), jsxs("ul", __assign({ className: 'tw-flex-row' }, { children: [jsx("li", { children: jsxs("label", __assign({ className: "tw-label tw-justify-normal tw-pt-1 tw-pb-0" }, { children: [jsx("input", { type: "checkbox", readOnly: true, className: "tw-checkbox tw-checkbox-xs tw-checkbox-success", checked: isAuthenticated ? isAuthenticated : false }), jsx("span", __assign({ className: 'tw-text-sm tw-label-text tw-mx-2' }, { children: "Sign Up" }))] })) }), jsx("li", { children: jsxs("label", __assign({ className: "tw-label tw-justify-normal tw-pt-1 tw-pb-0" }, { children: [jsx("input", { type: "checkbox", readOnly: true, className: "tw-checkbox tw-checkbox-xs tw-checkbox-success", checked: (user === null || user === void 0 ? void 0 : user.description) ? true : false }), jsx("span", __assign({ className: 'tw-text-sm tw-label-text tw-mx-2' }, { children: "Fill Profile" }))] })) }), jsx("li", { children: jsxs("label", __assign({ className: "tw-label tw-justify-normal tw-pt-1 tw-pb-0" }, { children: [jsx("input", { type: "checkbox", readOnly: true, className: "tw-checkbox tw-checkbox-xs tw-checkbox-success", checked: (user === null || user === void 0 ? void 0 : user.avatar) ? true : false }), jsx("span", __assign({ className: 'tw-text-sm tw-label-text tw-mx-2' }, { children: "Upload Avatar" }))] })) })] })), " "] })) }))
4961
+ jsx("div", __assign({ className: "tw-card tw-w-48 tw-bg-base-100 tw-shadow-xl tw-absolute tw-bottom-4 tw-left-4 tw-z-[2000]" }, { children: jsxs("div", __assign({ className: "tw-card-body tw-p-4 tw-pt-0" }, { children: [jsx("div", __assign({ className: "tw-card-actions tw-justify-end" }, { children: jsx("label", __assign({ className: "tw-btn tw-btn-sm tw-btn-circle tw-btn-ghost tw-absolute tw-right-1 tw-top-1", onClick: function () { return setQuestsOpen(false); } }, { children: "\u2715" })) })), jsxs("h2", __assign({ className: "tw-card-title tw-m-auto " }, { children: ["Level 1", jsx("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", strokeWidth: 1.5, stroke: "#aaa", className: "tw-w-5 tw-h-5 tw-cursor-pointer" }, { children: jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M9.879 7.519c1.171-1.025 3.071-1.025 4.242 0 1.172 1.025 1.172 2.687 0 3.712-.203.179-.43.326-.67.442-.745.361-1.45.999-1.45 1.827v.75M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9 5.25h.008v.008H12v-.008z" }) }))] })), jsxs("ul", __assign({ className: 'tw-flex-row' }, { children: [jsx("li", { children: jsxs("label", __assign({ className: "tw-label tw-justify-normal tw-pt-1 tw-pb-0" }, { children: [jsx("input", { type: "checkbox", readOnly: true, className: "tw-checkbox tw-checkbox-xs tw-checkbox-success", checked: isAuthenticated ? isAuthenticated : false }), jsx("span", __assign({ className: 'tw-text-sm tw-label-text tw-mx-2' }, { children: "Sign Up" }))] })) }), jsx("li", { children: jsxs("label", __assign({ className: "tw-label tw-justify-normal tw-pt-1 tw-pb-0" }, { children: [jsx("input", { type: "checkbox", readOnly: true, className: "tw-checkbox tw-checkbox-xs tw-checkbox-success", checked: (profile === null || profile === void 0 ? void 0 : profile.text) ? true : false }), jsx("span", __assign({ className: 'tw-text-sm tw-label-text tw-mx-2' }, { children: "Fill Profile" }))] })) }), jsx("li", { children: jsxs("label", __assign({ className: "tw-label tw-justify-normal tw-pt-1 tw-pb-0" }, { children: [jsx("input", { type: "checkbox", readOnly: true, className: "tw-checkbox tw-checkbox-xs tw-checkbox-success", checked: (profile === null || profile === void 0 ? void 0 : profile.image) ? true : false }), jsx("span", __assign({ className: 'tw-text-sm tw-label-text tw-mx-2' }, { children: "Upload Avatar" }))] })) })] })), " "] })) }))
4960
4962
  : "" }));
4961
4963
  }
4962
4964