@protobase/ui 0.21.11 → 0.21.12
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/app/app.js +1 -1
- package/dist/app/comments/comment-composer.js +1 -1
- package/dist/app/create/create-page.js +1 -1
- package/dist/app/create/create-values.js +2 -1
- package/dist/app/current-address.d.ts +1 -0
- package/dist/app/current-address.js +2 -1
- package/dist/app/displays/board-column.js +1 -1
- package/dist/app/displays/calendar-display.js +1 -1
- package/dist/app/displays/list-cards.js +1 -1
- package/dist/app/displays/map-display.js +1 -1
- package/dist/app/embedded-list/embedded-list.js +1 -1
- package/dist/app/field-editor.js +3 -3
- package/dist/app/gallery/detail-fields.js +2 -1
- package/dist/app/gallery/gallery-section.js +1 -1
- package/dist/app/gallery/photo-details.js +1 -1
- package/dist/app/group-open.js +7 -0
- package/dist/app/hand-order/hand-sorted-list.js +1 -1
- package/dist/app/incoming-relations.js +2 -1
- package/dist/app/list-page.js +1 -1
- package/dist/app/pages/action-inputs/action-inputs-dialog.js +1 -1
- package/dist/app/pages/blocks/card-row.js +1 -1
- package/dist/app/pages/blocks/modal-form.js +1 -1
- package/dist/app/pages/blocks/record-card.js +1 -1
- package/dist/app/pages/record-actions.js +1 -1
- package/dist/app/record-mode/shown-layout.js +13 -6
- package/dist/app/record-page.js +81 -64
- package/dist/app/record-row/record-row-body.js +1 -1
- package/dist/app/record-row/saved-record-row.js +1 -1
- package/dist/app/related-section.js +1 -1
- package/dist/app/searches/saved-search-rows.js +1 -1
- package/dist/app/searches/saved-searches.js +1 -1
- package/dist/app/sensitive-field.js +1 -1
- package/dist/app/use-app-address.d.ts +1 -0
- package/dist/app/use-record-editor.js +1 -1
- package/dist/forms/public-form-page.js +1 -1
- package/dist/index.js +1 -1
- package/dist/live/field-values.js +1 -1
- package/dist/package.js +1 -1
- package/dist/record-view/group-section.js +35 -0
- package/dist/shell/assets/app-IuP56Dep.js +69 -0
- package/dist/shell/assets/{index-CzqIlZPP.css → index-DhW8t8wq.css} +1 -1
- package/dist/shell/assets/{index-Dimu63Ym.js → index-GB5YRjlo.js} +1 -1
- package/dist/shell/assets/{maplibre-ERswanhA.js → maplibre-BLm41BrA.js} +1 -1
- package/dist/shell/assets/{markdown-content-D-haiVrI.js → markdown-content-Cia4jbSB.js} +1 -1
- package/dist/shell/assets/{record-map-C3i03kwc.js → record-map-C-Svn7nc.js} +1 -1
- package/dist/shell/assets/{records-map-C1JyIuz3.js → records-map-D5LZhC54.js} +1 -1
- package/dist/shell/assets/{shared-protobase-ui-Bt4hh6GB.js → shared-protobase-ui-D16YbnPr.js} +1 -1
- package/dist/shell/index.html +4 -4
- package/dist/shell/protobase.shell.json +1 -1
- package/package.json +4 -4
- package/dist/shell/assets/app-CiQapuHq.js +0 -69
|
@@ -5,10 +5,10 @@ import { useClient } from "../data/api-provider.js";
|
|
|
5
5
|
import { AuthLayout } from "../auth/auth-layout.js";
|
|
6
6
|
import { humanize } from "../live/naming.js";
|
|
7
7
|
import { Field } from "../record-view/field.js";
|
|
8
|
+
import { Notice } from "../app/meta-gate.js";
|
|
8
9
|
import { createBody, hasDatabaseDefault, initialDraft, isRequired } from "../app/create/create-values.js";
|
|
9
10
|
import { useDocumentTitle } from "../app/document-title.js";
|
|
10
11
|
import { ErrorBanner } from "../app/error-banner.js";
|
|
11
|
-
import { Notice } from "../app/meta-gate.js";
|
|
12
12
|
import { FieldEditor } from "../app/field-editor.js";
|
|
13
13
|
import { fieldErrors, fieldMessage } from "../app/field-errors.js";
|
|
14
14
|
import { useFocusFirstInvalid } from "../app/use-focus-first-invalid.js";
|
package/dist/index.js
CHANGED
|
@@ -18,9 +18,9 @@ import { useApiToken } from "./auth/use-api-token.js";
|
|
|
18
18
|
import { useRecord } from "./data/use-record.js";
|
|
19
19
|
import { Field } from "./record-view/field.js";
|
|
20
20
|
import { Section } from "./record-view/section.js";
|
|
21
|
-
import { Textarea } from "./primitives/textarea.js";
|
|
22
21
|
import { useMeta } from "./data/use-meta.js";
|
|
23
22
|
import { AppLink, useAppAddress } from "./app/use-app-address.js";
|
|
23
|
+
import { Textarea } from "./primitives/textarea.js";
|
|
24
24
|
import { useList } from "./data/use-list.js";
|
|
25
25
|
import { definePlugin, defineUi } from "./app/pages/project-ui.js";
|
|
26
26
|
import { ChatMessage } from "./chat/chat-message.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { localeDecimal, parseNumberText } from "../format/number-text.js";
|
|
2
1
|
import { fileDiffers, filePatchValue } from "./file-values.js";
|
|
2
|
+
import { localeDecimal, parseNumberText } from "../format/number-text.js";
|
|
3
3
|
//#region src/live/field-values.ts
|
|
4
4
|
/** What the editor's text input holds for a stored value. */
|
|
5
5
|
const toDraft = (value) => value === null || value === void 0 ? "" : typeof value === "object" ? JSON.stringify(value) : String(value);
|
package/dist/package.js
CHANGED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { cn } from "../lib/cn.js";
|
|
2
|
+
import { AppLink } from "../app/use-app-address.js";
|
|
3
|
+
import { useId } from "react";
|
|
4
|
+
import { ChevronRight } from "lucide-react";
|
|
5
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
//#region src/record-view/group-section.tsx
|
|
7
|
+
const headingClass = "text-[16px] font-semibold text-foreground";
|
|
8
|
+
/**
|
|
9
|
+
* A heading over sections of the record page. With `toggle`, the address that opens or closes it, the heading is a
|
|
10
|
+
* link, so a copied link opens the page with the group open; the items show only while `open`. Without it the group
|
|
11
|
+
* is always open.
|
|
12
|
+
*/
|
|
13
|
+
const GroupSection = ({ title, open, toggle, children }) => {
|
|
14
|
+
const id = useId();
|
|
15
|
+
return /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("h2", {
|
|
16
|
+
className: cn("py-8", open && "pb-0"),
|
|
17
|
+
children: toggle ? /* @__PURE__ */ jsxs(AppLink, {
|
|
18
|
+
to: toggle,
|
|
19
|
+
replace: true,
|
|
20
|
+
"aria-expanded": open,
|
|
21
|
+
"aria-controls": id,
|
|
22
|
+
className: cn("inline-flex items-center gap-1.5", headingClass),
|
|
23
|
+
children: [/* @__PURE__ */ jsx(ChevronRight, { className: cn("size-4 transition-transform", open && "rotate-90") }), title]
|
|
24
|
+
}) : /* @__PURE__ */ jsx("span", {
|
|
25
|
+
className: headingClass,
|
|
26
|
+
children: title
|
|
27
|
+
})
|
|
28
|
+
}), open && /* @__PURE__ */ jsx("div", {
|
|
29
|
+
id,
|
|
30
|
+
className: "divide-y divide-border",
|
|
31
|
+
children
|
|
32
|
+
})] });
|
|
33
|
+
};
|
|
34
|
+
//#endregion
|
|
35
|
+
export { GroupSection };
|