@lowdefy/docs-content 6.0.0 → 7.0.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.
Files changed (285) hide show
  1. package/README.md +1 -0
  2. package/content/actions/downloadcsv.md +1 -1
  3. package/content/actions/emailotpsend.md +58 -0
  4. package/content/actions/emailotpverify.md +79 -0
  5. package/content/actions/getlocalstorage.md +43 -0
  6. package/content/actions/link.md +47 -1
  7. package/content/actions/login.md +25 -5
  8. package/content/actions/logout.md +7 -5
  9. package/content/actions/magiclinkverify.md +117 -0
  10. package/content/actions/pdfmake.md +2 -2
  11. package/content/actions/posthogalias.md +29 -0
  12. package/content/actions/posthogcapture.md +49 -0
  13. package/content/actions/posthogcapturepageleave.md +38 -0
  14. package/content/actions/posthogfeatureflag.md +50 -0
  15. package/content/actions/posthoggroup.md +37 -0
  16. package/content/actions/posthogidentify.md +54 -0
  17. package/content/actions/posthoginit.md +96 -0
  18. package/content/actions/posthogoptin.md +29 -0
  19. package/content/actions/posthogoptout.md +29 -0
  20. package/content/actions/posthogpageview.md +37 -0
  21. package/content/actions/posthogreloadfeatureflags.md +47 -0
  22. package/content/actions/posthogreset.md +28 -0
  23. package/content/actions/posthogsetpersonproperties.md +36 -0
  24. package/content/actions/removelocalstorage.md +28 -0
  25. package/content/actions/resetvalidation.md +5 -3
  26. package/content/actions/setdarkmode.md +3 -3
  27. package/content/actions/setglobal.md +2 -0
  28. package/content/actions/setlocale.md +1 -1
  29. package/content/actions/setlocalstorage.md +34 -0
  30. package/content/actions/setstate.md +2 -0
  31. package/content/actions/validate.md +7 -4
  32. package/content/adapter-reference/mongodbauthadapter.md +46 -0
  33. package/content/agents/agent-endpoint-tools.md +24 -0
  34. package/content/agents/agent-properties.md +13 -3
  35. package/content/agents/agent-server-hooks.md +1 -1
  36. package/content/agents/agentchat.md +41 -4
  37. package/content/agents/agentconversations.md +42 -8
  38. package/content/agents/agents-introduction.md +107 -0
  39. package/content/callback-reference/auth0logoutcallback.md +54 -0
  40. package/content/concepts/ai-agent-docs.md +455 -106
  41. package/content/concepts/blocks.md +150 -0
  42. package/content/concepts/connections-and-requests.md +402 -0
  43. package/content/concepts/custom-html.md +42 -0
  44. package/content/concepts/custom-styling.md +50 -5
  45. package/content/concepts/dynamic-page-content.md +309 -0
  46. package/content/concepts/events-and-actions.md +185 -2
  47. package/content/concepts/four-primitives.md +31 -0
  48. package/content/concepts/html-attributes.md +293 -0
  49. package/content/concepts/i18n.md +12 -3
  50. package/content/concepts/keyboard-shortcuts.md +2 -2
  51. package/content/concepts/layout-overview.md +1 -1
  52. package/content/concepts/logger.md +99 -0
  53. package/content/concepts/lowdefy-api.md +1319 -0
  54. package/content/concepts/lowdefy-schema.md +144 -3
  55. package/content/concepts/menus.md +8 -7
  56. package/content/concepts/module-authoring.md +76 -5
  57. package/content/concepts/modules.md +3 -1
  58. package/content/concepts/notifications.md +180 -0
  59. package/content/concepts/operators.md +7 -0
  60. package/content/concepts/page-and-app-state.md +252 -0
  61. package/content/concepts/page-paths.md +209 -0
  62. package/content/concepts/theming.md +582 -0
  63. package/content/connections/aigateway.md +375 -0
  64. package/content/connections/anthropic.md +169 -2
  65. package/content/connections/awss3.md +178 -2
  66. package/content/connections/axioshttp.md +181 -0
  67. package/content/connections/google.md +169 -2
  68. package/content/connections/mongodb.md +1014 -3
  69. package/content/connections/openai-connection.md +169 -2
  70. package/content/connections/sendgridmail.md +3 -0
  71. package/content/connections/smtp.md +16 -0
  72. package/content/connections/treg.md +329 -0
  73. package/content/container-blocks/affix.md +47 -7
  74. package/content/container-blocks/alert.md +76 -24
  75. package/content/container-blocks/badge.md +100 -24
  76. package/content/container-blocks/box.md +9 -9
  77. package/content/container-blocks/card.md +132 -27
  78. package/content/container-blocks/carousel.md +60 -7
  79. package/content/container-blocks/collapse.md +153 -9
  80. package/content/container-blocks/configprovider.md +35 -13
  81. package/content/container-blocks/confirmmodal.md +69 -23
  82. package/content/container-blocks/content.md +62 -98
  83. package/content/container-blocks/descriptions.md +45 -4
  84. package/content/container-blocks/drawer.md +139 -28
  85. package/content/container-blocks/dropdownmenu.md +119 -31
  86. package/content/container-blocks/flex.md +40 -62
  87. package/content/container-blocks/footer.md +15 -11
  88. package/content/container-blocks/googlemapsheatmap.md +1 -1
  89. package/content/container-blocks/googlemapsscript.md +2 -2
  90. package/content/container-blocks/header.md +71 -36
  91. package/content/container-blocks/label.md +34 -7
  92. package/content/container-blocks/layout.md +52 -34
  93. package/content/container-blocks/masonry.md +17 -71
  94. package/content/container-blocks/mobilemenu.md +131 -88
  95. package/content/container-blocks/modal.md +161 -26
  96. package/content/container-blocks/pageheadermenu.md +138 -31
  97. package/content/container-blocks/pagesidebarlayout.md +230 -27
  98. package/content/container-blocks/pagesidermenu.md +153 -43
  99. package/content/container-blocks/popover.md +34 -31
  100. package/content/container-blocks/result.md +32 -21
  101. package/content/container-blocks/sider.md +85 -122
  102. package/content/container-blocks/span.md +7 -7
  103. package/content/container-blocks/spinner.md +3 -3
  104. package/content/container-blocks/splitter.md +150 -68
  105. package/content/container-blocks/tabs.md +64 -12
  106. package/content/container-blocks/tooltip.md +22 -46
  107. package/content/container-blocks/watermark.md +22 -4
  108. package/content/controls/parallel_for.md +21 -2
  109. package/content/controls/reject.md +26 -3
  110. package/content/controls/return.md +17 -1
  111. package/content/controls/throw.md +30 -2
  112. package/content/controls/try.md +24 -2
  113. package/content/controls/while.md +46 -0
  114. package/content/deployment/deployment-environments.md +146 -0
  115. package/content/deployment/docker.md +23 -7
  116. package/content/deployment/node-server.md +4 -0
  117. package/content/deployment/vercel.md +25 -19
  118. package/content/display-blocks/aggrid.md +33 -16
  119. package/content/display-blocks/anchor.md +16 -15
  120. package/content/display-blocks/avatar.md +57 -37
  121. package/content/display-blocks/breadcrumb.md +70 -21
  122. package/content/display-blocks/button.md +93 -19
  123. package/content/display-blocks/calendar.md +12 -0
  124. package/content/display-blocks/clickablehtml.md +239 -0
  125. package/content/display-blocks/dangeroushtml.md +1 -1
  126. package/content/display-blocks/difflist.md +1 -1
  127. package/content/display-blocks/difftimeline.md +1 -1
  128. package/content/display-blocks/divider.md +64 -3
  129. package/content/display-blocks/dropdownbutton.md +81 -30
  130. package/content/display-blocks/echart.md +35 -1
  131. package/content/display-blocks/eventlog.md +363 -0
  132. package/content/display-blocks/floatbutton.md +129 -42
  133. package/content/display-blocks/html.md +61 -1
  134. package/content/display-blocks/icon.md +250 -67
  135. package/content/display-blocks/img.md +2 -2
  136. package/content/display-blocks/menu.md +146 -73
  137. package/content/display-blocks/message.md +38 -124
  138. package/content/display-blocks/notification.md +94 -222
  139. package/content/display-blocks/paragraph.md +59 -9
  140. package/content/display-blocks/pollingtimer.md +263 -0
  141. package/content/display-blocks/progress.md +96 -17
  142. package/content/display-blocks/qrcode.md +19 -4
  143. package/content/display-blocks/s3download.md +1 -1
  144. package/content/display-blocks/search.md +19 -9
  145. package/content/display-blocks/skeletonbutton.md +1 -0
  146. package/content/display-blocks/skeletoninput.md +1 -0
  147. package/content/display-blocks/statistic.md +75 -17
  148. package/content/display-blocks/steps.md +58 -25
  149. package/content/display-blocks/table.md +2527 -0
  150. package/content/display-blocks/tablelight.md +621 -0
  151. package/content/display-blocks/tag.md +102 -17
  152. package/content/display-blocks/title.md +50 -11
  153. package/content/display-blocks/tour.md +33 -23
  154. package/content/input-blocks/autocomplete.md +81 -9
  155. package/content/input-blocks/buttonselector.md +45 -8
  156. package/content/input-blocks/captcha.md +40 -0
  157. package/content/input-blocks/checkboxselector.md +97 -7
  158. package/content/input-blocks/checkboxswitch.md +33 -3
  159. package/content/input-blocks/colorselector.md +63 -14
  160. package/content/input-blocks/daterangeselector.md +165 -45
  161. package/content/input-blocks/dateselector.md +139 -41
  162. package/content/input-blocks/datetimeselector.md +158 -49
  163. package/content/input-blocks/inputgallery.md +3 -3
  164. package/content/input-blocks/intentinput.md +207 -0
  165. package/content/input-blocks/monthselector.md +120 -52
  166. package/content/input-blocks/multipleselector.md +150 -39
  167. package/content/input-blocks/numberinput.md +98 -12
  168. package/content/input-blocks/pagination.md +70 -14
  169. package/content/input-blocks/paragraphinput.md +51 -37
  170. package/content/input-blocks/passwordinput.md +60 -6
  171. package/content/input-blocks/phonenumberinput.md +59 -26
  172. package/content/input-blocks/placesautocomplete.md +319 -0
  173. package/content/input-blocks/radioselector.md +83 -7
  174. package/content/input-blocks/ratingslider.md +57 -26
  175. package/content/input-blocks/s3uploadbutton.md +24 -24
  176. package/content/input-blocks/s3uploaddragger.md +3 -3
  177. package/content/input-blocks/s3uploadphoto.md +5 -5
  178. package/content/input-blocks/segmentedselector.md +72 -32
  179. package/content/input-blocks/selector.md +109 -21
  180. package/content/input-blocks/switch.md +65 -17
  181. package/content/input-blocks/tableinput.md +445 -0
  182. package/content/input-blocks/tagmultipleselector.md +114 -0
  183. package/content/input-blocks/tagselector.md +114 -0
  184. package/content/input-blocks/textarea.md +32 -3
  185. package/content/input-blocks/textinput.md +70 -29
  186. package/content/input-blocks/tiptapinput.md +1 -1
  187. package/content/input-blocks/tiptapmentioninput.md +2 -2
  188. package/content/input-blocks/titleinput.md +39 -12
  189. package/content/input-blocks/treeinput.md +49 -25
  190. package/content/input-blocks/treemultipleselector.md +127 -10
  191. package/content/input-blocks/treeselector.md +97 -9
  192. package/content/input-blocks/upload.md +64 -15
  193. package/content/input-blocks/uploaddragger.md +17 -1
  194. package/content/input-blocks/uploadphoto.md +18 -1
  195. package/content/input-blocks/weekselector.md +120 -55
  196. package/content/learn/introduction.md +27 -0
  197. package/content/learn/quickstart.md +53 -0
  198. package/content/learn/showcase.md +8 -0
  199. package/content/list-blocks/controlledlist.md +24 -15
  200. package/content/list-blocks/list.md +11 -11
  201. package/content/list-blocks/masonrylist.md +7 -34
  202. package/content/migration/auth-upgrade.md +337 -0
  203. package/content/migration/upgrade-guide.md +1 -0
  204. package/content/migration/v3-to-v4.md +417 -0
  205. package/content/migration/v6-to-v7.md +620 -0
  206. package/content/operators/_agent.md +155 -0
  207. package/content/operators/_app.md +2 -1
  208. package/content/operators/_array.md +122 -1
  209. package/content/operators/_build.md +1 -0
  210. package/content/operators/_credential.md +57 -0
  211. package/content/operators/_cron.md +292 -0
  212. package/content/operators/_date.md +2 -0
  213. package/content/operators/_error.md +196 -0
  214. package/content/operators/_get.md +6 -6
  215. package/content/operators/_hmac.md +78 -0
  216. package/content/operators/_js.md +2 -1
  217. package/content/operators/_location.md +1 -1
  218. package/content/operators/_media.md +13 -0
  219. package/content/operators/_module.md +56 -2
  220. package/content/operators/_operator.md +17 -3
  221. package/content/operators/_path_params.md +82 -0
  222. package/content/operators/_ref.md +258 -0
  223. package/content/operators/_request.md +1 -1
  224. package/content/operators/_request_details.md +6 -0
  225. package/content/operators/_type.md +14 -3
  226. package/content/operators/_url_query.md +2 -0
  227. package/content/operators/_user.md +3 -3
  228. package/content/plugins/plugins-actions.md +10 -0
  229. package/content/plugins/plugins-connections.md +25 -0
  230. package/content/plugins/plugins-dev.md +66 -0
  231. package/content/plugins/plugins-icon-sets.md +267 -0
  232. package/content/plugins/plugins-introduction.md +27 -1
  233. package/content/plugins/plugins.md +19 -0
  234. package/content/plugins/posthog.md +359 -0
  235. package/content/provider-reference/auth-js-providers.md +107 -0
  236. package/content/provider-reference/openidconnectprovider.md +44 -0
  237. package/content/recipes/recipes.md +16 -0
  238. package/content/reference/actions-reference.md +31 -0
  239. package/content/reference/blocks-reference.md +35 -0
  240. package/content/reference/cli.md +403 -0
  241. package/content/reference/connections-reference.md +23 -0
  242. package/content/reference/operators-reference.md +47 -0
  243. package/content/reference/reference.md +16 -0
  244. package/content/reference/schema-reference.md +12 -0
  245. package/content/testing/config-tests.md +677 -0
  246. package/content/testing/e2e-configuration.md +31 -1
  247. package/content/testing/e2e-getting-started.md +1 -1
  248. package/content/testing/e2e-introduction.md +1 -1
  249. package/content/testing/e2e-writing-tests.md +12 -1
  250. package/content/testing/explore-pull-request.md +136 -0
  251. package/content/testing/journey-data-sets.md +326 -0
  252. package/content/tutorial/tutorial-actions-operators.md +2 -2
  253. package/content/tutorial/tutorial-add-blocks.md +2 -2
  254. package/content/tutorial/tutorial-create-page.md +48 -2
  255. package/content/tutorial/tutorial-display-data-page.md +3 -3
  256. package/content/tutorial/tutorial-requests-api.md +155 -0
  257. package/content/tutorial/tutorial-requests-sql.md +153 -0
  258. package/content/tutorial/tutorial-start.md +66 -1
  259. package/content/user-authentication/auth-configuration.md +267 -0
  260. package/content/user-authentication/auth-providers.md +24 -0
  261. package/content/user-authentication/auth-steps.md +141 -0
  262. package/content/user-authentication/login-and-logout.md +160 -8
  263. package/content/user-authentication/mcp-oauth.md +424 -0
  264. package/content/user-authentication/organizations.md +246 -0
  265. package/content/user-authentication/protected-pages-apis.md +97 -0
  266. package/content/user-authentication/roles.md +49 -0
  267. package/content/user-authentication/two-factor.md +229 -0
  268. package/content/user-authentication/user-object.md +58 -0
  269. package/content/user-authentication/users-introduction.md +8 -0
  270. package/content/websockets/websocket-publish.md +105 -0
  271. package/content/websockets/websocket-subscriptions.md +136 -0
  272. package/content/websockets/websockets-introduction.md +101 -0
  273. package/hazards.json +56 -0
  274. package/index.json +3472 -14
  275. package/package.json +10 -1
  276. package/scripts/extractAgentDocs.js +41 -30
  277. package/scripts/hashDocSources.js +38 -0
  278. package/scripts/isRedirectPage.js +26 -0
  279. package/scripts/recordSourceHashes.js +97 -0
  280. package/scripts/resolvePageSections.js +42 -0
  281. package/scripts/sectionKind.js +27 -0
  282. package/content/concepts/cli.md +0 -223
  283. package/content/other/introduction.md +0 -39
  284. package/content/other/next-auth-providers.md +0 -3
  285. /package/content/{other → actions}/updatesession.md +0 -0
@@ -3,6 +3,7 @@
3
3
  This guide explains how the Lowdefy upgrade system works — independent of any specific version.
4
4
 
5
5
  For version-specific migration details, see:
6
+ - [Version 6 to Version 7](/v6-to-v7)
6
7
  - [Version 5 to Version 6](/v5-to-v6)
7
8
  - [Version 4 to Version 5](/v4-to-v5)
8
9
  - [Version 3 to Version 4](/v3-to-v4)
@@ -0,0 +1,417 @@
1
+ # Version 3 to Version 4
2
+
3
+ ## Payload on Requests
4
+
5
+ In version 3, the `state`, `global`, `input`, `urlQuery` and `event` data objects were sent with the request. This allowed the use of the [`_state`](/_state), [`_global`](/_global), [`_input`](/_input), [`_url_query`](/_url_query) and [`_event`](/_event) operators inside requests and connections. If the state became too large, this would result in a payload size exceeded error on request calls.
6
+
7
+ In version 4, these operators can no longer be used in requests, and request payloads are introduced. Payloads can be used to specify the data that should be sent with the request. The data specified in the payload can be accessed using the `_payload` operator. Operators are evaluated in the payload before it is sent, so operators such as [`_state`](/_state) and [`_global`](_global) can be used in the payload.
8
+
9
+ If only the [`_state`](/_state) operator was used, the entire state object can be set as the payload:
10
+
11
+ ###### Version 3:
12
+
13
+ ```yaml
14
+ id: api_call
15
+ type: AxiosHttp
16
+ connectionId: my_api
17
+ properties:
18
+ url: /products/new
19
+ method: post
20
+ data:
21
+ name:
22
+ _state: name
23
+ product_category:
24
+ _state: name
25
+ ```
26
+
27
+ ###### Version 4:
28
+
29
+ ```yaml
30
+ id: api_call
31
+ type: AxiosHttp
32
+ connectionId: my_api
33
+ payload:
34
+ _state: true
35
+ properties:
36
+ url: /products/new
37
+ method: post
38
+ data:
39
+ name:
40
+ _payload: name
41
+ product_category:
42
+ _payload: product_category
43
+ ```
44
+
45
+ The payload can also be created more explicitly using more than one operator type:
46
+
47
+ ###### Version 3:
48
+
49
+ ```yaml
50
+ id: api_call
51
+ type: AxiosHttp
52
+ connectionId: my_api
53
+ properties:
54
+ url: /products/update
55
+ method: post
56
+ data:
57
+ id:
58
+ _url_query: id
59
+ name:
60
+ _state: name
61
+ ```
62
+
63
+ ###### Version 4:
64
+
65
+ ```yaml
66
+ id: api_call
67
+ type: AxiosHttp
68
+ connectionId: my_api
69
+ payload:
70
+ id:
71
+ _url_query: id
72
+ name:
73
+ _state: name
74
+ properties:
75
+ url: /products/new
76
+ method: post
77
+ data:
78
+ id:
79
+ _payload: id
80
+ name:
81
+ _payload: name
82
+ ```
83
+
84
+ The `user` data object is still available in requests, and the [`_user`](/_user) operator should be used in the request properties not in they payload as malicious users can modify the data sent in payload.
85
+
86
+ ###### Don't do:
87
+
88
+ ```yaml
89
+ id: api_call
90
+ type: AxiosHttp
91
+ connectionId: my_api
92
+ payload:
93
+ # ...
94
+ created_by:
95
+ _user: id
96
+ properties:
97
+ url: /products/new
98
+ method: post
99
+ data:
100
+ # ...
101
+ created_by:
102
+ _payload: created_by
103
+ ```
104
+
105
+ ###### Do:
106
+
107
+ ```yaml
108
+ id: api_call
109
+ type: AxiosHttp
110
+ connectionId: my_api
111
+ payload:
112
+ # ...
113
+ properties:
114
+ url: /products/new
115
+ method: post
116
+ data:
117
+ # ...
118
+ created_by:
119
+ _user: id
120
+ ```
121
+
122
+ > If you see a warning message like `Operator type "_state" was used but is not defined.`, you are using the `_state` operator in a request's properties and should move it to payload.
123
+
124
+ ## Icons
125
+
126
+ The Ant Design icons used in version 3 have been replaced by [React Icons](https://react-icons.github.io/react-icons/), which has a much larger library of icons to choose from, including the Ant Design icons. To use a React Icon, set the `icon` or `icon.name` property to the React Icon name.
127
+
128
+ To convert existing Ant Design icons to React Icons, the icon names should be changed to the new format:
129
+
130
+ ###### Version 3:
131
+
132
+ ```yaml
133
+ id: save_button
134
+ type: Button
135
+ properties:
136
+ icon: SaveOutlined
137
+ ```
138
+
139
+ ###### Version 4:
140
+
141
+ ```yaml
142
+ # Using the same Ant Design icon
143
+ id: save_button
144
+ type: Button
145
+ properties:
146
+ icon: AiOutlineSave
147
+ ```
148
+
149
+ ```yaml
150
+ # Using the Font Awesome icon
151
+ id: save_button
152
+ type: Button
153
+ properties:
154
+ icon: FaRegSave
155
+ ```
156
+
157
+ ## Renames and Minor changes
158
+
159
+ The `Message` action has been renamed to [`DisplayMessage`](/DisplayMessage). Change the type name of `Message` actions to [`DisplayMessage`](/DisplayMessage).
160
+
161
+ The `onEnter` and `onEnterAsync` events have been removed as their functionality is duplicated by the `onMount` and `onMountAsync` events. Rename all `onEnter` and `onEnterAsync` events to `onMount` and `onMountAsync` respectively.
162
+
163
+ Duplicate action ids in the same action chain were allowed in version 3, but are not allowed in version 4. If you get a build error about duplicate action ids, give the actions unique ids.
164
+
165
+ The `Notification` action has been removed. Switch to the [`DisplayMessage`](/DisplayMessage) action, or use a [`Notification`](/Notification) block and the `CallMethod` action to open the notification.
166
+
167
+ The 404 page is now always a public page.
168
+
169
+ The [`Anchor`](/Anchor) block properties schema has changed. The `href` property has been removed and it now takes the same props as the [`Link`](/Link) action.
170
+
171
+ The [`_yaml.parse`](/_yaml) operator now takes an object with a `on` property or an array where the first argument is the string to parse, instead of just a string, to allow it to take additional options.
172
+
173
+ The `ChromeColorSelector`, `CircleColorSelector`, `CompactColorSelector`, `GithubColorSelector`, `SliderColorSelector`, `SwatchesColorSelector`, and `TwitterColorSelector` have been replaced by the [`ColorSelector`](/ColorSelector) block.
174
+
175
+ The `color` properties in blocks like [`MobileMenu`](/MobileMenu), [`PageHeaderMenu`](/PageHeaderMenu), [`PageSiderMenu`](/PageSiderMenu) have been removed. Use Ant Design theme less variables instead.
176
+
177
+ The [`_var`](/_var) operator `name` param has been renamed to `key` to be more consistent with other getter operators.
178
+
179
+ The `_format` operator has been replaced with the [`_intl`](/_intl) and [`_moment`](/_moment) operator, with some minor schema changes. Note: `_moment` was renamed to [`_dayjs`](/_dayjs) in v5.
180
+
181
+ The format of dates in the output of the [`_json.stringify`](/_json) and [`_yaml.stringify`](/_yaml) operators, as well as in URL query parameters has changed from `_date: {iso_date_string}` to `~d: {iso_date_string}`.
182
+
183
+ ## Block Loading States
184
+
185
+ The page loading states in version 4 have been improved. In general apps should load a lot faster. Blocks will now be a lot less likely to show a loading state and rather render as normal, and render their children. Input blocks will be disabled while in a loading state. This contributes to users seeing useful content sooner, and to less layout shifts once the app finishes loading.
186
+
187
+ In version 3, blocks had a `loading` property to specify the loading skeleton that should be used while the block is in a loading state. This functionality has been replaced by the `skeleton` property. The `loading` property is now used to control the loading state of the block. The block will be in a loading state if an `onInit` or `onMount` event is busy, if a parent block is loading or if the `loading` property evaluates to true. See more about loading [here](/blocks).
188
+
189
+ The convert from version 3 to version 4, replace the `loading` property on blocks with the `skeleton` property.
190
+
191
+ ###### Version 3:
192
+
193
+ ```yaml
194
+ id: paragraph_one
195
+ type: Markdown
196
+ loading:
197
+ type: SkeletonParagraph
198
+ properties:
199
+ lines: 5
200
+ properties:
201
+ content:
202
+ _request: get_text.body_text
203
+ ```
204
+
205
+ ###### Version 4:
206
+
207
+ ```yaml
208
+ id: paragraph_one
209
+ type: Markdown
210
+ skeleton:
211
+ type: SkeletonParagraph
212
+ properties:
213
+ lines: 5
214
+ properties:
215
+ content:
216
+ _request: get_text.body_text
217
+ ```
218
+
219
+ ```yaml
220
+ # Keep the block in loading while the request is loading
221
+ id: paragraph_one
222
+ type: Markdown
223
+ loading:
224
+ _eq:
225
+ - _request: get_text
226
+ - null
227
+ skeleton:
228
+ type: SkeletonParagraph
229
+ properties:
230
+ lines: 5
231
+ properties:
232
+ content:
233
+ _request: get_text.body_text
234
+ ```
235
+
236
+ ## Static files
237
+
238
+ Static files placed in the `public` folder of your project were always served from the public url path - for example `https://example.com/public/filename.jpeg`. These files are now served from the root path of your app. The example above will now be served from `https://example.com/filename.jpeg`. This allows you to serve files like `robots.txt` and `sitemap.xml` from the root path. Change all references in your config to the new paths.
239
+
240
+ If you still want to serve assets under the `/public` path, you can add an addition `public` folder inside the existing `public` folder:
241
+
242
+ ```txt
243
+ .
244
+ ├─ public
245
+ │ └─ public
246
+ │ └─ my-logo.jpeg
247
+ └─ lowdefy.yaml
248
+ ```
249
+
250
+ ## Authentication Changes
251
+
252
+ In version 4, authentication has been reworked to use [NextAuth.js](https://next-auth.js.org), which offers a lot more flexibility and additional features - read more [here](/users-introduction).
253
+
254
+ To migrate a version 3 OpenID Connect provider, at least the following needs to be done:
255
+ - The `config.auth` property has moved to the `auth` root level property.
256
+ - The `config.auth.openId` properties have been removed, replace them with configuration for your provider:
257
+ ```yaml
258
+ auth:
259
+ providers:
260
+ - id: auth0
261
+ type: Auth0Provider
262
+ properties:
263
+ clientId:
264
+ _secret: AUTH0_CLIENT_ID
265
+ clientSecret:
266
+ _secret: AUTH0_CLIENT_SECRET
267
+ issuer:
268
+ _secret: AUTH0_ISSUER
269
+ ```
270
+
271
+ - The `NEXTAUTH_SECRET` environment variable needs to be set to a secure secret value (replacing `LOWDEFY_SECRET_JWT_SECRET`).
272
+ - The callback URLs configured with the provider change from `{{ protocol }}{{ host }}/auth/openid-callback` to `{{ protocol }}{{ host }}/api/auth/callback/{{ providerId }}`.
273
+ - The `Login` and `Logout` action params have changed between V3 and V4.
274
+
275
+ ## Custom Blocks, Actions and Operators
276
+
277
+ Custom blocks, the `JsAction` action and the `_js` operator have been replaced by the new Lowdefy plugin system which is an easier, more powerful and standardized way to extend actions, blocks, connections, operators and the authentication system with custom JavaScript. See the [plugin documentation](/plugins-introduction) for more information on how to use and develop plugins.
278
+
279
+ The [AgGrid](https://github.com/lowdefy/blocks-aggrid) custom blocks have been added as default Lowdefy blocks, so these blocks can now be used without any additional configuration.
280
+
281
+ ## Context has been removed
282
+
283
+ In version 3, the first block on a page needed to be a `context` category block. This was because in version 3 you could have multiple context blocks on the same page, each with it's own separate state.
284
+
285
+ This feature was found to be unnecessary, created additional complexity and was difficult to understand, so it was removed.
286
+
287
+ The `Context` type block was removed, as it was a `Box` block that also created a context. The `Context` block can be replaced by a `Box`.
288
+
289
+ If the `Context` block is no longer necessary it can also be removed:
290
+
291
+ ###### Version 3:
292
+
293
+ ```yaml
294
+ id: '404'
295
+ type: Context
296
+ style:
297
+ minHeight: 100vh
298
+ blocks:
299
+ - id: 404_result
300
+ type: Result
301
+ properties:
302
+ status: 404
303
+ title: '404'
304
+ subTitle: Sorry, the page you are visiting does not exist.
305
+ ```
306
+
307
+ ###### Version 4:
308
+
309
+ ```yaml
310
+ id: '404'
311
+ type: Result
312
+ style:
313
+ minHeight: 100vh
314
+ properties:
315
+ status: 404
316
+ title: '404'
317
+ subTitle: Sorry, the page you are visiting does not exist.
318
+ ```
319
+
320
+ ## Other removed blocks
321
+
322
+ In version 4 the `PageHCF`, `PageHCSF`, `PageHSCF`, and `PageSHCF` blocks have been removed. Instead you can now use the `Layout`, `Header`, `Content`, `Sider` and `Footer` blocks. See more about this [here](https://4x.ant.design/components/layout/).
323
+
324
+ ###### Layout, Header-Content-Footer example:
325
+
326
+ ```yaml
327
+ id: layout
328
+ type: Layout
329
+ style:
330
+ textAlign: center
331
+ blocks:
332
+ - id: header
333
+ type: Header
334
+ blocks:
335
+ - id: Title
336
+ type: Title
337
+ properties:
338
+ content: Header
339
+ style:
340
+ backgroundColor: red
341
+ - id: content
342
+ type: Content
343
+ blocks:
344
+ - id: Title
345
+ type: Title
346
+ style:
347
+ backgroundColor: green
348
+ properties:
349
+ content: Content
350
+ - id: footer
351
+ type: Footer
352
+ blocks:
353
+ - id: Title
354
+ type: Title
355
+ style:
356
+ backgroundColor: blue
357
+ properties:
358
+ content: Footer
359
+ ```
360
+
361
+ ## Server Configuration
362
+
363
+ The `LOWDEFY_SERVER_BASE_PATH` environment variable configuration option has been removed. To configure a base path, use the `config.basePath` configuration option.
364
+
365
+ ``yaml
366
+ lowdefy: 6.1.0
367
+
368
+ config:
369
+ basePath: /foo
370
+ ```
371
+
372
+ The `_build.env` operator can be used to set the base path using an environment variable:
373
+ ```yaml
374
+ lowdefy: 6.1.0
375
+
376
+ config:
377
+ basePath:
378
+ _build.env: LOWDEFY_BASE_PATH
379
+ ```
380
+
381
+ The `LOWDEFY_SERVER_PUBLIC_DIRECTORY` and `LOWDEFY_SERVER_BUILD_DIRECTORY` are no longer supported because configuration is bundled with the server at build time.
382
+
383
+ The `LOWDEFY_SERVER_PORT` environment variable has been replaced by the `PORT` environment variable.
384
+
385
+ ## _change_case
386
+
387
+ The options splitRegex and stripRegex are no longer supported in v4 and the following have been renamed:
388
+ - paramCase to kebabCase
389
+ - headerCase to trainCase
390
+
391
+ ###### Version 3:
392
+
393
+ ```yaml
394
+ _change_case.paramCase:
395
+ on: example string
396
+ ```
397
+
398
+ ###### Version 4:
399
+
400
+ ```yaml
401
+ _change_case.kebabCase:
402
+ on: example string
403
+ ```
404
+
405
+ ###### Version 3:
406
+
407
+ ```yaml
408
+ _change_case.headerCase:
409
+ on: example string
410
+ ```
411
+
412
+ ###### Version 4:
413
+
414
+ ```yaml
415
+ _change_case.trainCase:
416
+ on: example string
417
+ ```