@lowdefy/docs-content 0.0.0-experimental-20260710073520
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/LICENSE +201 -0
- package/README.md +20 -0
- package/content/actions/callapi.md +66 -0
- package/content/actions/callmethod.md +41 -0
- package/content/actions/copytoclipboard.md +32 -0
- package/content/actions/displaymessage.md +53 -0
- package/content/actions/downloadcsv.md +89 -0
- package/content/actions/fetch.md +50 -0
- package/content/actions/geolocationcurrentposition.md +56 -0
- package/content/actions/link.md +104 -0
- package/content/actions/login.md +85 -0
- package/content/actions/logout.md +56 -0
- package/content/actions/pdfmake.md +304 -0
- package/content/actions/request.md +67 -0
- package/content/actions/reset.md +27 -0
- package/content/actions/resetvalidation.md +85 -0
- package/content/actions/scrollto.md +85 -0
- package/content/actions/setdarkmode.md +62 -0
- package/content/actions/setfocus.md +33 -0
- package/content/actions/setglobal.md +63 -0
- package/content/actions/setlocale.md +69 -0
- package/content/actions/setstate.md +70 -0
- package/content/actions/throw.md +72 -0
- package/content/actions/validate.md +87 -0
- package/content/actions/wait.md +24 -0
- package/content/agents/agent-endpoint-tools.md +190 -0
- package/content/agents/agent-mcp-tools.md +124 -0
- package/content/agents/agent-multi-agent.md +136 -0
- package/content/agents/agent-properties.md +174 -0
- package/content/agents/agent-server-hooks.md +336 -0
- package/content/agents/agentchat.md +515 -0
- package/content/agents/agentconversations.md +148 -0
- package/content/concepts/ai-agent-docs.md +190 -0
- package/content/concepts/cli.md +213 -0
- package/content/concepts/connections-and-requests.md +7 -0
- package/content/concepts/custom-html.md +3 -0
- package/content/concepts/custom-styling.md +161 -0
- package/content/concepts/events-and-actions.md +271 -0
- package/content/concepts/hosting-files.md +18 -0
- package/content/concepts/i18n.md +320 -0
- package/content/concepts/keyboard-shortcuts.md +218 -0
- package/content/concepts/layout-overview.md +478 -0
- package/content/concepts/lists.md +144 -0
- package/content/concepts/logger.md +43 -0
- package/content/concepts/lowdefy-schema.md +365 -0
- package/content/concepts/menus.md +144 -0
- package/content/concepts/module-authoring.md +564 -0
- package/content/concepts/modules.md +338 -0
- package/content/concepts/operators.md +45 -0
- package/content/concepts/overview.md +19 -0
- package/content/concepts/references-and-templates.md +207 -0
- package/content/concepts/secrets.md +24 -0
- package/content/concepts/selectors.md +143 -0
- package/content/connections/amazonredshift.md +176 -0
- package/content/connections/anthropic.md +232 -0
- package/content/connections/awss3.md +313 -0
- package/content/connections/azureblobstorage.md +133 -0
- package/content/connections/elasticsearch.md +371 -0
- package/content/connections/google.md +228 -0
- package/content/connections/googlecloudstorage.md +139 -0
- package/content/connections/googlesheet.md +313 -0
- package/content/connections/knex.md +206 -0
- package/content/connections/mariadb.md +177 -0
- package/content/connections/mcp.md +134 -0
- package/content/connections/mongodb.md +739 -0
- package/content/connections/mssql.md +191 -0
- package/content/connections/mysql.md +192 -0
- package/content/connections/openai-connection.md +228 -0
- package/content/connections/postgresql.md +200 -0
- package/content/connections/redis.md +116 -0
- package/content/connections/sendgridmail.md +94 -0
- package/content/connections/smtp.md +149 -0
- package/content/connections/sqlite.md +187 -0
- package/content/connections/stripe.md +115 -0
- package/content/container-blocks/affix.md +413 -0
- package/content/container-blocks/alert.md +937 -0
- package/content/container-blocks/badge.md +1222 -0
- package/content/container-blocks/box.md +1453 -0
- package/content/container-blocks/card.md +1200 -0
- package/content/container-blocks/carousel.md +2247 -0
- package/content/container-blocks/collapse.md +1335 -0
- package/content/container-blocks/configprovider.md +1070 -0
- package/content/container-blocks/confirmmodal.md +1159 -0
- package/content/container-blocks/content.md +597 -0
- package/content/container-blocks/descriptions.md +870 -0
- package/content/container-blocks/drawer.md +1379 -0
- package/content/container-blocks/dropdownmenu.md +643 -0
- package/content/container-blocks/flex.md +1510 -0
- package/content/container-blocks/footer.md +380 -0
- package/content/container-blocks/googlemaps.md +546 -0
- package/content/container-blocks/googlemapsheatmap.md +607 -0
- package/content/container-blocks/googlemapsscript.md +61 -0
- package/content/container-blocks/header.md +302 -0
- package/content/container-blocks/label.md +739 -0
- package/content/container-blocks/layout.md +604 -0
- package/content/container-blocks/masonry.md +1090 -0
- package/content/container-blocks/mobilemenu.md +1244 -0
- package/content/container-blocks/modal.md +1180 -0
- package/content/container-blocks/pageheadermenu.md +614 -0
- package/content/container-blocks/pagesidebarlayout.md +438 -0
- package/content/container-blocks/pagesidermenu.md +651 -0
- package/content/container-blocks/popover.md +1421 -0
- package/content/container-blocks/result.md +972 -0
- package/content/container-blocks/sider.md +1064 -0
- package/content/container-blocks/span.md +747 -0
- package/content/container-blocks/spinner.md +267 -0
- package/content/container-blocks/splitter.md +1735 -0
- package/content/container-blocks/tabs.md +1718 -0
- package/content/container-blocks/tooltip.md +1274 -0
- package/content/container-blocks/watermark.md +515 -0
- package/content/controls/for.md +103 -0
- package/content/controls/if.md +107 -0
- package/content/controls/log.md +50 -0
- package/content/controls/parallel.md +71 -0
- package/content/controls/parallel_for.md +36 -0
- package/content/controls/reject.md +56 -0
- package/content/controls/return.md +66 -0
- package/content/controls/set_state.md +98 -0
- package/content/controls/switch.md +90 -0
- package/content/controls/throw.md +79 -0
- package/content/controls/try.md +88 -0
- package/content/deployment/docker.md +149 -0
- package/content/deployment/node-server.md +27 -0
- package/content/deployment/vercel.md +101 -0
- package/content/display-blocks/aggrid.md +1459 -0
- package/content/display-blocks/anchor.md +336 -0
- package/content/display-blocks/avatar.md +1154 -0
- package/content/display-blocks/breadcrumb.md +517 -0
- package/content/display-blocks/button.md +758 -0
- package/content/display-blocks/calendar.md +156 -0
- package/content/display-blocks/dangeroushtml.md +314 -0
- package/content/display-blocks/dangerousmarkdown.md +423 -0
- package/content/display-blocks/diffgit.md +44 -0
- package/content/display-blocks/difflist.md +225 -0
- package/content/display-blocks/diffsidebyside.md +56 -0
- package/content/display-blocks/difftimeline.md +94 -0
- package/content/display-blocks/divider.md +406 -0
- package/content/display-blocks/download.md +60 -0
- package/content/display-blocks/dropdownbutton.md +661 -0
- package/content/display-blocks/echart.md +418 -0
- package/content/display-blocks/floatbutton.md +545 -0
- package/content/display-blocks/html.md +311 -0
- package/content/display-blocks/icon.md +717 -0
- package/content/display-blocks/img.md +479 -0
- package/content/display-blocks/markdown.md +520 -0
- package/content/display-blocks/markdownwithcode.md +730 -0
- package/content/display-blocks/menu.md +1123 -0
- package/content/display-blocks/message.md +941 -0
- package/content/display-blocks/notification.md +1410 -0
- package/content/display-blocks/paragraph.md +643 -0
- package/content/display-blocks/progress.md +818 -0
- package/content/display-blocks/qrcode.md +519 -0
- package/content/display-blocks/s3download.md +240 -0
- package/content/display-blocks/search.md +360 -0
- package/content/display-blocks/skeleton.md +272 -0
- package/content/display-blocks/skeletonavatar.md +222 -0
- package/content/display-blocks/skeletonbutton.md +245 -0
- package/content/display-blocks/skeletoninput.md +223 -0
- package/content/display-blocks/skeletonparagraph.md +201 -0
- package/content/display-blocks/statistic.md +485 -0
- package/content/display-blocks/steps.md +585 -0
- package/content/display-blocks/tag.md +620 -0
- package/content/display-blocks/title.md +654 -0
- package/content/display-blocks/tour.md +2359 -0
- package/content/input-blocks/autocomplete.md +786 -0
- package/content/input-blocks/buttonselector.md +964 -0
- package/content/input-blocks/checkboxselector.md +765 -0
- package/content/input-blocks/checkboxswitch.md +497 -0
- package/content/input-blocks/colorselector.md +884 -0
- package/content/input-blocks/daterangeselector.md +777 -0
- package/content/input-blocks/dateselector.md +693 -0
- package/content/input-blocks/datetimeselector.md +791 -0
- package/content/input-blocks/inputgallery.md +528 -0
- package/content/input-blocks/monthselector.md +717 -0
- package/content/input-blocks/multipleselector.md +1337 -0
- package/content/input-blocks/numberinput.md +855 -0
- package/content/input-blocks/pagination.md +679 -0
- package/content/input-blocks/paragraphinput.md +1664 -0
- package/content/input-blocks/passwordinput.md +480 -0
- package/content/input-blocks/phonenumberinput.md +688 -0
- package/content/input-blocks/radioselector.md +820 -0
- package/content/input-blocks/ratingslider.md +684 -0
- package/content/input-blocks/s3uploadbutton.md +384 -0
- package/content/input-blocks/s3uploaddragger.md +305 -0
- package/content/input-blocks/s3uploadphoto.md +288 -0
- package/content/input-blocks/segmentedselector.md +782 -0
- package/content/input-blocks/selector.md +1162 -0
- package/content/input-blocks/switch.md +552 -0
- package/content/input-blocks/textarea.md +714 -0
- package/content/input-blocks/textinput.md +639 -0
- package/content/input-blocks/tiptapinput.md +226 -0
- package/content/input-blocks/tiptapmentioninput.md +471 -0
- package/content/input-blocks/titleinput.md +1094 -0
- package/content/input-blocks/treeinput.md +144 -0
- package/content/input-blocks/treemultipleselector.md +162 -0
- package/content/input-blocks/treeselector.md +185 -0
- package/content/input-blocks/upload.md +149 -0
- package/content/input-blocks/uploaddragger.md +85 -0
- package/content/input-blocks/uploadphoto.md +84 -0
- package/content/input-blocks/weekselector.md +630 -0
- package/content/list-blocks/controlledlist.md +498 -0
- package/content/list-blocks/list.md +529 -0
- package/content/list-blocks/listselector.md +301 -0
- package/content/list-blocks/masonrylist.md +230 -0
- package/content/migration/upgrade-guide.md +106 -0
- package/content/migration/v4-to-v5.md +589 -0
- package/content/migration/v5-to-v6.md +36 -0
- package/content/operators/_actions.md +58 -0
- package/content/operators/_and.md +76 -0
- package/content/operators/_api.md +254 -0
- package/content/operators/_app.md +114 -0
- package/content/operators/_args.md +65 -0
- package/content/operators/_array.md +331 -0
- package/content/operators/_base64.md +49 -0
- package/content/operators/_boolean.md +33 -0
- package/content/operators/_build.md +166 -0
- package/content/operators/_change_case.md +357 -0
- package/content/operators/_date.md +415 -0
- package/content/operators/_dayjs.md +128 -0
- package/content/operators/_diff.md +61 -0
- package/content/operators/_divide.md +32 -0
- package/content/operators/_eq.md +52 -0
- package/content/operators/_event.md +86 -0
- package/content/operators/_function.md +52 -0
- package/content/operators/_get.md +92 -0
- package/content/operators/_global.md +86 -0
- package/content/operators/_gt.md +50 -0
- package/content/operators/_gte.md +50 -0
- package/content/operators/_hash.md +112 -0
- package/content/operators/_if.md +30 -0
- package/content/operators/_if_none.md +47 -0
- package/content/operators/_index.md +48 -0
- package/content/operators/_input.md +86 -0
- package/content/operators/_intl.md +135 -0
- package/content/operators/_item.md +166 -0
- package/content/operators/_js.md +113 -0
- package/content/operators/_json.md +120 -0
- package/content/operators/_jsonata.md +152 -0
- package/content/operators/_locale.md +65 -0
- package/content/operators/_location.md +40 -0
- package/content/operators/_log.md +22 -0
- package/content/operators/_lt.md +50 -0
- package/content/operators/_lte.md +50 -0
- package/content/operators/_math.md +407 -0
- package/content/operators/_media.md +83 -0
- package/content/operators/_menu.md +62 -0
- package/content/operators/_module.md +340 -0
- package/content/operators/_mql.md +95 -0
- package/content/operators/_ne.md +62 -0
- package/content/operators/_not.md +33 -0
- package/content/operators/_number.md +159 -0
- package/content/operators/_nunjucks.md +117 -0
- package/content/operators/_object.md +253 -0
- package/content/operators/_operator.md +33 -0
- package/content/operators/_or.md +67 -0
- package/content/operators/_product.md +45 -0
- package/content/operators/_random.md +90 -0
- package/content/operators/_ref.md +80 -0
- package/content/operators/_regex.md +69 -0
- package/content/operators/_request.md +35 -0
- package/content/operators/_request_details.md +29 -0
- package/content/operators/_secret.md +56 -0
- package/content/operators/_state.md +134 -0
- package/content/operators/_step.md +98 -0
- package/content/operators/_string.md +327 -0
- package/content/operators/_subtract.md +24 -0
- package/content/operators/_sum.md +45 -0
- package/content/operators/_switch.md +37 -0
- package/content/operators/_t.md +96 -0
- package/content/operators/_theme.md +65 -0
- package/content/operators/_type.md +78 -0
- package/content/operators/_uri.md +49 -0
- package/content/operators/_url_query.md +92 -0
- package/content/operators/_user.md +154 -0
- package/content/operators/_uuid.md +118 -0
- package/content/operators/_var.md +88 -0
- package/content/operators/_yaml.md +96 -0
- package/content/other/introduction.md +39 -0
- package/content/other/next-auth-providers.md +3 -0
- package/content/other/updatesession.md +26 -0
- package/content/plugins/plugins-actions.md +80 -0
- package/content/plugins/plugins-connections.md +98 -0
- package/content/plugins/plugins-dev.md +138 -0
- package/content/plugins/plugins-introduction.md +29 -0
- package/content/plugins/plugins-operators.md +71 -0
- package/content/testing/e2e-auth.md +108 -0
- package/content/testing/e2e-configuration.md +107 -0
- package/content/testing/e2e-getting-started.md +96 -0
- package/content/testing/e2e-introduction.md +53 -0
- package/content/testing/e2e-mocking.md +155 -0
- package/content/testing/e2e-writing-tests.md +214 -0
- package/content/tutorial/tutorial-actions-operators.md +222 -0
- package/content/tutorial/tutorial-add-blocks.md +86 -0
- package/content/tutorial/tutorial-create-page.md +57 -0
- package/content/tutorial/tutorial-display-data-page.md +181 -0
- package/content/tutorial/tutorial-next-steps.md +53 -0
- package/content/tutorial/tutorial-requests-sql.md +22 -0
- package/content/tutorial/tutorial-start.md +71 -0
- package/content/user-authentication/auth-providers.md +15 -0
- package/content/user-authentication/login-and-logout.md +122 -0
- package/content/user-authentication/users-introduction.md +31 -0
- package/index.json +2281 -0
- package/package.json +34 -0
- package/scripts/extractAgentDocs.js +130 -0
|
@@ -0,0 +1,589 @@
|
|
|
1
|
+
# Version 4 to Version 5
|
|
2
|
+
|
|
3
|
+
This guide covers all breaking changes and new features when upgrading from Lowdefy v4 to v5.
|
|
4
|
+
|
|
5
|
+
## Summary of breaking changes
|
|
6
|
+
|
|
7
|
+
| Change | Impact | Action |
|
|
8
|
+
|---|---|---|
|
|
9
|
+
| `_moment` → `_dayjs` | All apps using `_moment` | Find-and-replace |
|
|
10
|
+
| `areas` → `slots` | All container blocks | Find-and-replace (backwards compatible) |
|
|
11
|
+
| `styles.less` → `styles.css` | Apps with custom Less styles | Rewrite in CSS |
|
|
12
|
+
| Less variables → theme tokens | Apps using `@primary-color` etc. | Move to `theme.antd.token` |
|
|
13
|
+
| `style.sm` responsive → Tailwind | Apps using responsive style breakpoints | Use Tailwind classes |
|
|
14
|
+
| `bordered` → `variant` | 16 input/display blocks | Update property |
|
|
15
|
+
| `visible` → `open` | Modal | Update property |
|
|
16
|
+
| Button `type`/`danger` → `color`/`variant` | Button blocks | Update properties |
|
|
17
|
+
| Inline style props → `style: { .key }` | Card, Modal, Drawer, etc. | Update properties |
|
|
18
|
+
| Comment block removed | Apps using Comment | Use Card + Flex + Avatar |
|
|
19
|
+
| `_menu` returns links directly | Apps using `_menu` with `_get` | Simplify to `_menu: menuId` |
|
|
20
|
+
| Property renames | Various blocks | See table below |
|
|
21
|
+
|
|
22
|
+
## `_menu` returns links array directly
|
|
23
|
+
|
|
24
|
+
The `_menu` operator now returns the `links` array directly when selecting a single menu by ID. It also supports dot-path access into the result.
|
|
25
|
+
|
|
26
|
+
### Before (v4)
|
|
27
|
+
```yaml
|
|
28
|
+
# Get links required _get wrapper
|
|
29
|
+
_get:
|
|
30
|
+
key: links
|
|
31
|
+
from:
|
|
32
|
+
_menu: profile_menu
|
|
33
|
+
|
|
34
|
+
# Access through links
|
|
35
|
+
_get:
|
|
36
|
+
key: links.0.pageId
|
|
37
|
+
from:
|
|
38
|
+
_menu: search_links
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### After (v5)
|
|
42
|
+
```yaml
|
|
43
|
+
# Links returned directly
|
|
44
|
+
_menu: profile_menu
|
|
45
|
+
|
|
46
|
+
# Dot-path access
|
|
47
|
+
_menu: search_links.0.pageId
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
`_menu: true` and `_menu: { all: true }` still return the full menus array. A codemod is available to automate the conversion.
|
|
51
|
+
|
|
52
|
+
## `_moment` renamed to [`_dayjs`](/_dayjs)
|
|
53
|
+
|
|
54
|
+
The `_moment` operator has been renamed to `_dayjs`. The underlying library has changed from [Moment.js](https://momentjs.com/) to [Day.js](https://day.js.org/), which is significantly smaller (~2KB vs ~70KB).
|
|
55
|
+
|
|
56
|
+
A codemod is available to automate the rename — run `lowdefy upgrade` in your project directory.
|
|
57
|
+
|
|
58
|
+
Alternatively, this is a simple find-and-replace in your YAML config files:
|
|
59
|
+
|
|
60
|
+
### Before (v4)
|
|
61
|
+
```yaml
|
|
62
|
+
_moment.format:
|
|
63
|
+
on:
|
|
64
|
+
_date: 2019-06-04
|
|
65
|
+
format: 'D MMM YYYY'
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### After (v5)
|
|
69
|
+
```yaml
|
|
70
|
+
_dayjs.format:
|
|
71
|
+
on:
|
|
72
|
+
_date: 2019-06-04
|
|
73
|
+
format: 'D MMM YYYY'
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
### humanizeDuration
|
|
77
|
+
|
|
78
|
+
#### Before (v4)
|
|
79
|
+
```yaml
|
|
80
|
+
_moment.humanizeDuration:
|
|
81
|
+
on: 245923000
|
|
82
|
+
withSuffix: true
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
#### After (v5)
|
|
86
|
+
```yaml
|
|
87
|
+
_dayjs.humanizeDuration:
|
|
88
|
+
on: 245923000
|
|
89
|
+
withSuffix: true
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
### `thresholds` parameter dropped
|
|
93
|
+
|
|
94
|
+
The `thresholds` parameter on `humanizeDuration` is accepted but ignored in v5. Day.js uses fixed thresholds internally. If you relied on custom thresholds, the output may differ slightly.
|
|
95
|
+
|
|
96
|
+
### Locale names
|
|
97
|
+
|
|
98
|
+
The `_dayjs` operator auto-normalizes locale names (e.g. `en-US` becomes `en`, `zh-CN` becomes `zh-cn`). In nunjucks date filters, locale names must be lowercase.
|
|
99
|
+
|
|
100
|
+
22 locales are bundled: `af`, `de`, `en`, `es`, `fr`, `hi`, `it`, `ja`, `ko`, `nl`, `pl`, `pt`, `ru`, `sv`, `th`, `tr`, `uk`, `vi`, `zh-cn`, `zh-tw`, `ar`, `he`. Uncommon locales fall back to English silently.
|
|
101
|
+
|
|
102
|
+
### AgGrid cell renderers
|
|
103
|
+
|
|
104
|
+
If you use `_moment` inside `_function` blocks (e.g. AgGrid cell renderers), update the operator name:
|
|
105
|
+
|
|
106
|
+
#### Before (v4)
|
|
107
|
+
```yaml
|
|
108
|
+
cellRenderer:
|
|
109
|
+
_function:
|
|
110
|
+
__moment.format:
|
|
111
|
+
on:
|
|
112
|
+
__args: 0.data.date
|
|
113
|
+
format: 'D MMM YYYY'
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
#### After (v5)
|
|
117
|
+
```yaml
|
|
118
|
+
cellRenderer:
|
|
119
|
+
_function:
|
|
120
|
+
__dayjs.format:
|
|
121
|
+
on:
|
|
122
|
+
__args: 0.data.date
|
|
123
|
+
format: 'D MMM YYYY'
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
## [Layout Grid System](/layout-overview)
|
|
127
|
+
|
|
128
|
+
The layout grid system has been rewritten from the Ant Design Row/Col grid to a standalone CSS custom properties grid using Tailwind CSS breakpoints.
|
|
129
|
+
|
|
130
|
+
### Breakpoint changes
|
|
131
|
+
|
|
132
|
+
Breakpoint values have shifted to match Tailwind CSS v4 defaults, and `xxl` has been renamed to `2xl`:
|
|
133
|
+
|
|
134
|
+
| Breakpoint | v4 | v5 |
|
|
135
|
+
|---|---|---|
|
|
136
|
+
| `xs` | < 576px | < 640px |
|
|
137
|
+
| `sm` | >= 576px | >= 640px |
|
|
138
|
+
| `md` | >= 768px | >= 768px |
|
|
139
|
+
| `lg` | >= 992px | >= 1024px |
|
|
140
|
+
| `xl` | >= 1200px | >= 1280px |
|
|
141
|
+
| `xxl` / `2xl` | >= 1600px | >= 1536px |
|
|
142
|
+
|
|
143
|
+
Update any `xxl` responsive keys to `2xl`:
|
|
144
|
+
|
|
145
|
+
```yaml
|
|
146
|
+
# Before
|
|
147
|
+
layout:
|
|
148
|
+
span: 8
|
|
149
|
+
xxl:
|
|
150
|
+
span: 4
|
|
151
|
+
|
|
152
|
+
# After
|
|
153
|
+
layout:
|
|
154
|
+
span: 8
|
|
155
|
+
2xl:
|
|
156
|
+
span: 4
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
### `gutter` renamed to `gap`
|
|
160
|
+
|
|
161
|
+
The `gutter` property on area/slot config has been renamed to `gap`:
|
|
162
|
+
|
|
163
|
+
```yaml
|
|
164
|
+
# Before
|
|
165
|
+
slots:
|
|
166
|
+
content:
|
|
167
|
+
gutter: 16
|
|
168
|
+
|
|
169
|
+
# After
|
|
170
|
+
slots:
|
|
171
|
+
content:
|
|
172
|
+
gap: 16
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
### `content*` prefix removed from layout properties
|
|
176
|
+
|
|
177
|
+
Layout properties that controlled the content area no longer use the `content` prefix. These properties are set on the parent block's `layout` and flow to the content area as defaults:
|
|
178
|
+
|
|
179
|
+
| v4 | v5 |
|
|
180
|
+
|---|---|
|
|
181
|
+
| `contentGutter` / `contentGap` | `gap` |
|
|
182
|
+
| `contentAlign` | `align` |
|
|
183
|
+
| `contentJustify` | `justify` |
|
|
184
|
+
| `contentDirection` | `direction` |
|
|
185
|
+
| `contentWrap` | `wrap` |
|
|
186
|
+
| `contentOverflow` | `overflow` |
|
|
187
|
+
|
|
188
|
+
```yaml
|
|
189
|
+
# Before
|
|
190
|
+
layout:
|
|
191
|
+
span: 12
|
|
192
|
+
contentGutter: 16
|
|
193
|
+
contentAlign: middle
|
|
194
|
+
contentJustify: center
|
|
195
|
+
contentDirection: column
|
|
196
|
+
|
|
197
|
+
# After
|
|
198
|
+
layout:
|
|
199
|
+
span: 12
|
|
200
|
+
gap: 16
|
|
201
|
+
align: middle
|
|
202
|
+
justify: center
|
|
203
|
+
direction: column
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
### `layout.align` renamed to `layout.selfAlign`
|
|
207
|
+
|
|
208
|
+
The `layout.align` property (which controlled the block's own vertical alignment within its parent row) has been renamed to `layout.selfAlign`. The `layout.align` property now controls content area children alignment:
|
|
209
|
+
|
|
210
|
+
```yaml
|
|
211
|
+
# Before — block self-alignment
|
|
212
|
+
layout:
|
|
213
|
+
span: 6
|
|
214
|
+
align: top
|
|
215
|
+
|
|
216
|
+
# After — renamed to selfAlign
|
|
217
|
+
layout:
|
|
218
|
+
span: 6
|
|
219
|
+
selfAlign: top
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
### `span: 0` behavior change
|
|
223
|
+
|
|
224
|
+
Setting `span: 0` now hides the block (`display: none`) instead of making it full-width.
|
|
225
|
+
|
|
226
|
+
### [`_media`](/_media) operator
|
|
227
|
+
|
|
228
|
+
The `_media` operator now returns `"2xl"` instead of `"xxl"` for the largest breakpoint. Update any comparisons:
|
|
229
|
+
|
|
230
|
+
```yaml
|
|
231
|
+
# Before
|
|
232
|
+
_if:
|
|
233
|
+
condition:
|
|
234
|
+
_eq:
|
|
235
|
+
- _media: size
|
|
236
|
+
- xxl
|
|
237
|
+
then: ...
|
|
238
|
+
|
|
239
|
+
# After
|
|
240
|
+
_if:
|
|
241
|
+
condition:
|
|
242
|
+
_eq:
|
|
243
|
+
- _media: size
|
|
244
|
+
- 2xl
|
|
245
|
+
then: ...
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
### Responsive `style` breakpoints removed
|
|
249
|
+
|
|
250
|
+
Responsive breakpoint settings on the `style` property have been removed. Only `layout` supports responsive breakpoints. Use Tailwind CSS responsive classes via `class` instead:
|
|
251
|
+
|
|
252
|
+
```yaml
|
|
253
|
+
# Before
|
|
254
|
+
style:
|
|
255
|
+
padding: 64
|
|
256
|
+
sm:
|
|
257
|
+
padding: 32
|
|
258
|
+
|
|
259
|
+
# After
|
|
260
|
+
class: "p-16 sm:p-8"
|
|
261
|
+
```
|
|
262
|
+
|
|
263
|
+
A codemod is available to automate many of these changes — run `lowdefy upgrade` in your project directory.
|
|
264
|
+
|
|
265
|
+
## `areas` renamed to `slots`
|
|
266
|
+
|
|
267
|
+
The `areas` key on container and list blocks has been renamed to `slots`. This change is **backwards compatible** — `areas` will still work but is deprecated. We recommend updating to `slots` for consistency with the new documentation.
|
|
268
|
+
|
|
269
|
+
### Before (v4)
|
|
270
|
+
```yaml
|
|
271
|
+
- id: my_card
|
|
272
|
+
type: Card
|
|
273
|
+
areas:
|
|
274
|
+
content:
|
|
275
|
+
blocks:
|
|
276
|
+
- id: my_block
|
|
277
|
+
type: Box
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
### After (v5)
|
|
281
|
+
```yaml
|
|
282
|
+
- id: my_card
|
|
283
|
+
type: Card
|
|
284
|
+
slots:
|
|
285
|
+
content:
|
|
286
|
+
blocks:
|
|
287
|
+
- id: my_block
|
|
288
|
+
type: Box
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
## Style system migration
|
|
292
|
+
|
|
293
|
+
The entire styling system has changed from Less/emotion to CSS-in-JS with Tailwind CSS.
|
|
294
|
+
|
|
295
|
+
### `styles.less` → `styles.css`
|
|
296
|
+
|
|
297
|
+
Rename your `public/styles.less` file to `public/styles.css` and convert any Less syntax to plain CSS.
|
|
298
|
+
|
|
299
|
+
#### Before (v4)
|
|
300
|
+
```less
|
|
301
|
+
@primary-color: #2ac8bb;
|
|
302
|
+
@new-color: #2ac8bb;
|
|
303
|
+
|
|
304
|
+
h1 {
|
|
305
|
+
font-size: 32px;
|
|
306
|
+
color: @new-color;
|
|
307
|
+
}
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
#### After (v5)
|
|
311
|
+
```css
|
|
312
|
+
h1 {
|
|
313
|
+
font-size: 32px;
|
|
314
|
+
color: #2ac8bb;
|
|
315
|
+
}
|
|
316
|
+
```
|
|
317
|
+
|
|
318
|
+
For theme variable overrides, use `theme.antd.token` in `lowdefy.yaml` instead:
|
|
319
|
+
|
|
320
|
+
```yaml
|
|
321
|
+
theme:
|
|
322
|
+
antd:
|
|
323
|
+
token:
|
|
324
|
+
colorPrimary: '#2ac8bb'
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
### Responsive `style` breakpoints → Tailwind classes
|
|
328
|
+
|
|
329
|
+
The responsive `style.sm`, `style.md` etc. syntax has been removed. Use Tailwind CSS responsive classes via the `class` property instead:
|
|
330
|
+
|
|
331
|
+
#### Before (v4)
|
|
332
|
+
```yaml
|
|
333
|
+
- id: my_card
|
|
334
|
+
type: Card
|
|
335
|
+
style:
|
|
336
|
+
padding: 64
|
|
337
|
+
sm:
|
|
338
|
+
padding: 32
|
|
339
|
+
```
|
|
340
|
+
|
|
341
|
+
#### After (v5)
|
|
342
|
+
```yaml
|
|
343
|
+
- id: my_card
|
|
344
|
+
type: Card
|
|
345
|
+
class: "p-16 sm:p-8"
|
|
346
|
+
```
|
|
347
|
+
|
|
348
|
+
### Inline style props → `style: { .key }`
|
|
349
|
+
|
|
350
|
+
Block-specific inline style properties have been replaced with the unified `style` property using `.`-prefixed CSS slot keys:
|
|
351
|
+
|
|
352
|
+
| Block | Remove | Use instead |
|
|
353
|
+
|---|---|---|
|
|
354
|
+
| [Card](/Card) | `headerStyle`, `bodyStyle` | `style: { .header }`, `style: { .body }` |
|
|
355
|
+
| [Modal](/Modal) | `bodyStyle`, `maskStyle` | `style: { .body }`, `style: { .mask }` |
|
|
356
|
+
| [Drawer](/Drawer) | `drawerStyle`, `headerStyle`, `bodyStyle`, `maskStyle`, `contentWrapperStyle` | `style: { .wrapper }`, `style: { .header }`, `style: { .body }`, `style: { .mask }`, `style: { .content }` |
|
|
357
|
+
| [Tabs](/Tabs) | `tabBarStyle` | `style: { .tabBar }` |
|
|
358
|
+
| ConfirmModal | `bodyStyle` | `style: { .body }` |
|
|
359
|
+
| [Statistic](/Statistic) | `valueStyle` | `style: { .value }` |
|
|
360
|
+
| [Descriptions](/Descriptions) | `contentStyle`, `labelStyle` | `style: { .content }`, `style: { .label }` |
|
|
361
|
+
| [Tooltip](/Tooltip) | `overlayStyle` | `style: { .inner }` |
|
|
362
|
+
|
|
363
|
+
#### Before (v4)
|
|
364
|
+
```yaml
|
|
365
|
+
- id: my_card
|
|
366
|
+
type: Card
|
|
367
|
+
properties:
|
|
368
|
+
bodyStyle:
|
|
369
|
+
backgroundColor: "#f0f0f0"
|
|
370
|
+
headerStyle:
|
|
371
|
+
fontWeight: bold
|
|
372
|
+
```
|
|
373
|
+
|
|
374
|
+
#### After (v5)
|
|
375
|
+
```yaml
|
|
376
|
+
- id: my_card
|
|
377
|
+
type: Card
|
|
378
|
+
style:
|
|
379
|
+
.body:
|
|
380
|
+
backgroundColor: "#f0f0f0"
|
|
381
|
+
.header:
|
|
382
|
+
fontWeight: bold
|
|
383
|
+
```
|
|
384
|
+
|
|
385
|
+
## Theme migration
|
|
386
|
+
|
|
387
|
+
Less variables are replaced by antd design tokens. Configure tokens in `lowdefy.yaml`:
|
|
388
|
+
|
|
389
|
+
| Less variable (v4) | Theme token (v5) |
|
|
390
|
+
|---|---|
|
|
391
|
+
| `@primary-color` | `colorPrimary` |
|
|
392
|
+
| `@success-color` | `colorSuccess` |
|
|
393
|
+
| `@warning-color` | `colorWarning` |
|
|
394
|
+
| `@error-color` | `colorError` |
|
|
395
|
+
| `@font-size-base` | `fontSize` |
|
|
396
|
+
| `@border-radius-base` | `borderRadius` |
|
|
397
|
+
| `@text-color` | `colorTextBase` |
|
|
398
|
+
| `@heading-color` | `colorTextHeading` |
|
|
399
|
+
| `@disabled-color` | `colorTextDisabled` |
|
|
400
|
+
| `@border-color-base` | `colorBorder` |
|
|
401
|
+
| `@body-background` | `colorBgBase` |
|
|
402
|
+
| `@component-background` | `colorBgContainer` |
|
|
403
|
+
|
|
404
|
+
#### Before (v4)
|
|
405
|
+
```less
|
|
406
|
+
@primary-color: #6366f1;
|
|
407
|
+
@border-radius-base: 8px;
|
|
408
|
+
```
|
|
409
|
+
|
|
410
|
+
#### After (v5)
|
|
411
|
+
```yaml
|
|
412
|
+
# lowdefy.yaml
|
|
413
|
+
theme:
|
|
414
|
+
antd:
|
|
415
|
+
token:
|
|
416
|
+
colorPrimary: '#6366f1'
|
|
417
|
+
borderRadius: 8
|
|
418
|
+
```
|
|
419
|
+
|
|
420
|
+
Dark and compact modes:
|
|
421
|
+
```yaml
|
|
422
|
+
# Before: @import 'antd/dist/antd.dark.less';
|
|
423
|
+
# After:
|
|
424
|
+
theme:
|
|
425
|
+
antd:
|
|
426
|
+
algorithm: dark
|
|
427
|
+
```
|
|
428
|
+
|
|
429
|
+
See the [Theming](/theming) concept page for full details.
|
|
430
|
+
|
|
431
|
+
## Property renames
|
|
432
|
+
|
|
433
|
+
| Block | Old property | New property |
|
|
434
|
+
|---|---|---|
|
|
435
|
+
| [Modal](/Modal) | `visible` | `open` |
|
|
436
|
+
| [Tooltip](/Tooltip) | `defaultVisible` | `defaultOpen` |
|
|
437
|
+
| Tooltip | event `onVisibleChange` | event `onOpenChange` |
|
|
438
|
+
| [Progress](/Progress) | `gapPosition` | `gapPlacement` |
|
|
439
|
+
| [Carousel](/Carousel) | `dotPosition` | `dotPlacement` |
|
|
440
|
+
| [Collapse](/Collapse) | `expandIconPosition` | `expandIconPlacement` |
|
|
441
|
+
| Collapse | `bordered` | `variant` (`outlined` / `borderless`) |
|
|
442
|
+
| [Notification](/Notification) | `message` | `title` |
|
|
443
|
+
| [Tabs](/Tabs) | `tabPosition` | `tabPlacement` (`left` → `start`, `right` → `end`) |
|
|
444
|
+
| [Divider](/Divider) | `type` | `orientation` |
|
|
445
|
+
| Divider | `orientation` | `titlePlacement` (`start` / `center` / `end`) |
|
|
446
|
+
|
|
447
|
+
## `bordered` → `variant`
|
|
448
|
+
|
|
449
|
+
16 blocks have replaced the `bordered` boolean with a `variant` enum for more control:
|
|
450
|
+
|
|
451
|
+
| Old | New |
|
|
452
|
+
|---|---|
|
|
453
|
+
| `bordered: true` (default) | `variant: outlined` (default) |
|
|
454
|
+
| `bordered: false` | `variant: borderless` |
|
|
455
|
+
| — | `variant: filled` (new option) |
|
|
456
|
+
|
|
457
|
+
Affected blocks: [AutoComplete](/AutoComplete), [Card](/Card), [Collapse](/Collapse), [Descriptions](/Descriptions), [DateSelector](/DateSelector), [DateRangeSelector](/DateRangeSelector), [DateTimeSelector](/DateTimeSelector), [MonthSelector](/MonthSelector), [WeekSelector](/WeekSelector), [MultipleSelector](/MultipleSelector), [NumberInput](/NumberInput), [PasswordInput](/PasswordInput), [PhoneNumberInput](/PhoneNumberInput), [Selector](/Selector), [TextArea](/TextArea), [TextInput](/TextInput).
|
|
458
|
+
|
|
459
|
+
## [Button](/Button) `type`/`danger` → `color`/`variant`
|
|
460
|
+
|
|
461
|
+
The Button block has a new property API:
|
|
462
|
+
|
|
463
|
+
| Old (v4) | New (v5) |
|
|
464
|
+
|---|---|
|
|
465
|
+
| `type: primary` | `color: primary`, `variant: solid` |
|
|
466
|
+
| `type: dashed` | `variant: dashed` |
|
|
467
|
+
| `type: text` | `variant: text` |
|
|
468
|
+
| `type: link` | `variant: link` |
|
|
469
|
+
| `danger: true` | `color: danger` |
|
|
470
|
+
|
|
471
|
+
#### Before (v4)
|
|
472
|
+
```yaml
|
|
473
|
+
- id: my_button
|
|
474
|
+
type: Button
|
|
475
|
+
properties:
|
|
476
|
+
title: Delete
|
|
477
|
+
type: primary
|
|
478
|
+
danger: true
|
|
479
|
+
```
|
|
480
|
+
|
|
481
|
+
#### After (v5)
|
|
482
|
+
```yaml
|
|
483
|
+
- id: my_button
|
|
484
|
+
type: Button
|
|
485
|
+
properties:
|
|
486
|
+
title: Delete
|
|
487
|
+
color: danger
|
|
488
|
+
variant: solid
|
|
489
|
+
```
|
|
490
|
+
|
|
491
|
+
## Date blocks
|
|
492
|
+
|
|
493
|
+
The internal date library has changed from Moment.js to Day.js. Standard date format strings (`YYYY-MM-DD`, `YYYY-MM-DD HH:mm:ss`) work identically. If you use custom format strings, verify they produce the expected output — some moment.js-specific tokens may differ in dayjs.
|
|
494
|
+
|
|
495
|
+
The date blocks — [DateSelector](/DateSelector), [DateRangeSelector](/DateRangeSelector), [DateTimeSelector](/DateTimeSelector), [MonthSelector](/MonthSelector), and [WeekSelector](/WeekSelector) — also have the `bordered` → `variant` change described above.
|
|
496
|
+
|
|
497
|
+
## Removed blocks
|
|
498
|
+
|
|
499
|
+
### Comment
|
|
500
|
+
|
|
501
|
+
The Comment block has been removed (it was removed from antd v5). Use a composition pattern with [Card](/Card), [Flex](/Flex), [Avatar](/Avatar), and [Paragraph](/Paragraph) instead:
|
|
502
|
+
|
|
503
|
+
```yaml
|
|
504
|
+
- id: comment
|
|
505
|
+
type: Card
|
|
506
|
+
properties:
|
|
507
|
+
size: small
|
|
508
|
+
blocks:
|
|
509
|
+
- id: comment_header
|
|
510
|
+
type: Flex
|
|
511
|
+
properties:
|
|
512
|
+
align: center
|
|
513
|
+
gap: small
|
|
514
|
+
blocks:
|
|
515
|
+
- id: avatar
|
|
516
|
+
type: Avatar
|
|
517
|
+
properties:
|
|
518
|
+
color: '#402B18'
|
|
519
|
+
content: TD
|
|
520
|
+
- id: author
|
|
521
|
+
type: Paragraph
|
|
522
|
+
properties:
|
|
523
|
+
content: "**The Dude** — 18 January, 1998"
|
|
524
|
+
- id: comment_content
|
|
525
|
+
type: Paragraph
|
|
526
|
+
properties:
|
|
527
|
+
content: "Yeah, well, you know, that's just, like, your opinion, man."
|
|
528
|
+
```
|
|
529
|
+
|
|
530
|
+
## New blocks
|
|
531
|
+
|
|
532
|
+
The following blocks are new in v5:
|
|
533
|
+
|
|
534
|
+
| Block | Category | Description |
|
|
535
|
+
|---|---|---|
|
|
536
|
+
| [FloatButton](/FloatButton) | display | Floating action button |
|
|
537
|
+
| [Tour](/Tour) | display | Guided tour component |
|
|
538
|
+
| [QRCode](/QRCode) | display | QR code generator |
|
|
539
|
+
| [ColorSelector](/ColorSelector) | input | Color picker input (renamed from ColorPicker) |
|
|
540
|
+
| [SegmentedSelector](/SegmentedSelector) | input | Segmented control selector (renamed from Segmented) |
|
|
541
|
+
| [Flex](/Flex) | container | Flexbox layout container |
|
|
542
|
+
| [Splitter](/Splitter) | container | Resizable split-pane container |
|
|
543
|
+
| [Masonry](/Masonry) | container | Masonry (Pinterest-style) layout |
|
|
544
|
+
| [MasonryList](/MasonryList) | list | Data-driven masonry layout |
|
|
545
|
+
| [DropdownMenu](/DropdownMenu) | container | Dropdown navigation menu |
|
|
546
|
+
| [DropdownButton](/DropdownButton) | input | Button with dropdown menu |
|
|
547
|
+
| [Search](/Search) | input | Command palette search |
|
|
548
|
+
| [Watermark](/Watermark) | container | Watermark overlay container |
|
|
549
|
+
| [ConfigProvider](/ConfigProvider) | container | Scoped theme provider |
|
|
550
|
+
|
|
551
|
+
## Removed packages
|
|
552
|
+
|
|
553
|
+
### `@lowdefy/blocks-color-selectors`
|
|
554
|
+
|
|
555
|
+
The `@lowdefy/blocks-color-selectors` package has been removed. The `ColorPicker` block has been renamed to `ColorSelector` and moved to `@lowdefy/blocks-antd`. Update your config:
|
|
556
|
+
|
|
557
|
+
```yaml
|
|
558
|
+
# Before (v4)
|
|
559
|
+
- id: color
|
|
560
|
+
type: ColorPicker
|
|
561
|
+
|
|
562
|
+
# After (v5)
|
|
563
|
+
- id: color
|
|
564
|
+
type: ColorSelector
|
|
565
|
+
```
|
|
566
|
+
|
|
567
|
+
### `@lowdefy/blocks-algolia`
|
|
568
|
+
|
|
569
|
+
The `@lowdefy/blocks-algolia` package has been removed. Use the new `Search` block in `@lowdefy/blocks-antd` instead, which provides a MiniSearch-powered command palette search with pre-built index support, grouped results, and keyboard navigation. See [Search](/Search).
|
|
570
|
+
|
|
571
|
+
## New features
|
|
572
|
+
|
|
573
|
+
- **`class` property** — Apply Tailwind CSS classes to any block. See [Custom Styling](/custom-styling).
|
|
574
|
+
- **`style` with `.` keys** — Apply inline styles to specific parts of a block using CSS slot keys (e.g. `style: { .header: {...} }`).
|
|
575
|
+
- **`properties.theme`** — Override antd design tokens per block.
|
|
576
|
+
- **`_theme` operator** — Access theme seed tokens in expressions. See [`_theme`](/_theme).
|
|
577
|
+
- **Theming system** — App-level, component-level, and block-level theme customization. See [Theming](/theming).
|
|
578
|
+
- **Keyboard shortcuts** — Add `events.onClick.shortcut: 'mod+k'` to any event for platform-aware keyboard shortcuts. Blocks like [Button](/Button), [Anchor](/Anchor), [Tag](/Tag), and [Menu](/Menu) render a `ShortcutBadge` automatically.
|
|
579
|
+
- **`lowdefy upgrade` CLI** — Run `lowdefy upgrade` to automatically migrate your config from v4 to v5. Includes 20 codemods covering antd prop renames, layout grid migration, dayjs migration, and more. Supports `--plan`, `--dry-run`, and `--resume`.
|
|
580
|
+
- **ECharts v6** — Upgraded to echarts 6.0.0 with improved flex container sizing.
|
|
581
|
+
|
|
582
|
+
## Common pitfalls
|
|
583
|
+
|
|
584
|
+
1. **`styles.less` not loading** — Rename to `styles.css`. Less is no longer supported.
|
|
585
|
+
2. **`style.sm` not working** — Use `class: "... sm:..."` with Tailwind responsive classes instead.
|
|
586
|
+
3. **`bordered: false` not working** — Use `variant: borderless`.
|
|
587
|
+
4. **`@primary-color` not working** — Use `theme.antd.token.colorPrimary` in `lowdefy.yaml`.
|
|
588
|
+
5. **Button looks different** — Update `type` to `color`/`variant`. See the mapping table above.
|
|
589
|
+
6. **`areas` deprecated warning** — Rename `areas` to `slots` in your config.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# Version 5 to Version 6
|
|
2
|
+
|
|
3
|
+
This guide covers all breaking changes when upgrading from Lowdefy v5 to v6.
|
|
4
|
+
|
|
5
|
+
Lowdefy v6 replaces the Next.js framework with a [Hono](https://hono.dev) server and a [Vite](https://vite.dev)-built React client, and moves authentication from NextAuth v4 to [Auth.js](https://authjs.dev). **Your YAML config does not change** — `lowdefy build`, `lowdefy dev` and `lowdefy start` work as before, and plugin changes in dev now hot-reload in well under a second instead of triggering a full rebuild.
|
|
6
|
+
|
|
7
|
+
## Summary of breaking changes
|
|
8
|
+
|
|
9
|
+
| Change | Impact | Action |
|
|
10
|
+
|---|---|---|
|
|
11
|
+
| Server runs on Hono + Vite (not Next.js) | All apps | No config change |
|
|
12
|
+
| Custom `next.config.js` no longer applies | Apps with bundler customizations | Move to `vite.config.js` |
|
|
13
|
+
| Auth engine is Auth.js (not NextAuth v4) | Apps using auth | Users sign in again once; config unchanged |
|
|
14
|
+
| `NEXTAUTH_SECRET` / `NEXTAUTH_URL` deprecated | Apps using auth | Prefer `AUTH_SECRET` / `AUTH_URL` (old names still work) |
|
|
15
|
+
| `LOWDEFY_BUILD_OUTPUT_STANDALONE` removed | Docker / standalone deploys | Deploy the `.lowdefy/server` folder |
|
|
16
|
+
| `NEXT_PUBLIC_SENTRY_DSN` removed | Apps using Sentry | Set `SENTRY_DSN` only |
|
|
17
|
+
| CLI `--no-next-build` renamed | Deployment scripts | Use `--no-client-build` (old flag is a deprecated alias) |
|
|
18
|
+
| Page navigation is client-side (SPA) | All apps | No action; full reloads no longer happen on navigation |
|
|
19
|
+
|
|
20
|
+
## Server runs on Hono + Vite
|
|
21
|
+
|
|
22
|
+
The production server is a [Hono](https://hono.dev) app serving a [Vite](https://vite.dev)-built React client, and the dev server hot-reloads plugin changes through Vite instead of rebuilding the whole app. Things to check when upgrading:
|
|
23
|
+
|
|
24
|
+
- **Custom `next.config.js` files no longer apply.** If you customized the client bundler, move the customization to a `vite.config.js` in the server directory.
|
|
25
|
+
- **`LOWDEFY_BUILD_OUTPUT_STANDALONE` is removed.** `lowdefy build` writes a complete runnable server to `<config-directory>/.lowdefy/server` — copy that folder and run `node src/index.js` (or `pnpm start`) inside it. See the updated [Docker](/docker) and [node server](/node-server) guides.
|
|
26
|
+
- **`NEXT_PUBLIC_SENTRY_DSN` is removed.** Set `SENTRY_DSN` on the server — it is passed to the browser client at runtime, so rotating the DSN no longer requires a rebuild.
|
|
27
|
+
- **The CLI `--no-next-build` flag is now `--no-client-build`.** The old flag still works as a deprecated alias.
|
|
28
|
+
- **Page navigation is client-side.** The first page load embeds config in the HTML; navigating between pages fetches page config without a full browser reload.
|
|
29
|
+
|
|
30
|
+
## Auth engine is Auth.js
|
|
31
|
+
|
|
32
|
+
Authentication now runs on [Auth.js](https://authjs.dev) instead of NextAuth v4. The `auth:` configuration schema — providers, adapters, callbacks, events, session options and protected pages — is **unchanged**. Things to know when upgrading:
|
|
33
|
+
|
|
34
|
+
- **Users sign in again once.** The session cookie prefix changes from `next-auth.*` to `authjs.*`, so existing sessions are invalidated on upgrade.
|
|
35
|
+
- **`NEXTAUTH_SECRET` and `NEXTAUTH_URL` still work**, but `AUTH_SECRET` and `AUTH_URL` are the preferred names going forward.
|
|
36
|
+
- **Email sign-in flows expect `nodemailer@^7`.** Auth.js declares a `nodemailer@^7` peer dependency. Custom email providers (or plugins) that pin `nodemailer@6` keep working but log a peer-dependency warning during install — upgrade the `nodemailer` dependency in your app or plugin to `^7` to clear it.
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# _actions
|
|
2
|
+
|
|
3
|
+
```
|
|
4
|
+
(key: string): any
|
|
5
|
+
(all: boolean): any
|
|
6
|
+
(arguments: {
|
|
7
|
+
all?: boolean,
|
|
8
|
+
key?: string,
|
|
9
|
+
default?: any,
|
|
10
|
+
}): any
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
The `_actions` operator returns the response value for a preceding action in the same event list.
|
|
14
|
+
|
|
15
|
+
The action response object has the following structure:
|
|
16
|
+
```yaml
|
|
17
|
+
error: Error,
|
|
18
|
+
index: number,
|
|
19
|
+
response: any,
|
|
20
|
+
skipped: boolean,
|
|
21
|
+
type: string,
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Actions the event does not execute for a control-flow reason — actions in an untaken [`:if`](/:if) branch, in an unmatched [`:switch`](/:switch) case, or after a [`:return`](/:return) — are recorded as `skipped: true`, the same as actions skipped by their own `skip` field. Their operators are not evaluated, and `_actions` lookups on them return the skipped response object. Skipped entries are recorded in config order: when a branch executes, untaken branches written above it (an untaken `:then` when `:else` runs, or already-unmatched earlier cases) are recorded and readable, while branches below it are only recorded once the control completes. Actions after the control can read all of them.
|
|
25
|
+
|
|
26
|
+
#### Arguments
|
|
27
|
+
|
|
28
|
+
###### string
|
|
29
|
+
If the `_actions` operator is called with a string equal to a preceding action id in the same event list, the action response object returned. If a string is passed which does not match preceding action id in the same event list, `null` is returned. Dot notation is supported.
|
|
30
|
+
|
|
31
|
+
###### boolean
|
|
32
|
+
If the `_actions` operator is called with boolean argument `true`, an object with all the preceding action id responses in the same event list is returned.
|
|
33
|
+
|
|
34
|
+
#### Examples
|
|
35
|
+
|
|
36
|
+
##### Using a action response:
|
|
37
|
+
```yaml
|
|
38
|
+
_actions: my_action.response
|
|
39
|
+
```
|
|
40
|
+
Returns: The response returned by the action.
|
|
41
|
+
|
|
42
|
+
##### Setting a action response to `state`:
|
|
43
|
+
```yaml
|
|
44
|
+
id: refresh
|
|
45
|
+
type: Button
|
|
46
|
+
events:
|
|
47
|
+
onClick:
|
|
48
|
+
- id: get_fresh_data
|
|
49
|
+
type: Request
|
|
50
|
+
skip:
|
|
51
|
+
_state: should_not_fetch
|
|
52
|
+
params: get_data
|
|
53
|
+
- id: set_data
|
|
54
|
+
type: SetState
|
|
55
|
+
params:
|
|
56
|
+
did_not_fetch_data:
|
|
57
|
+
_actions: get_fresh_data.skipped
|
|
58
|
+
```
|