You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: examples/official-site/sqlpage/migrations/01_documentation.sql
+15-8Lines changed: 15 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -418,16 +418,21 @@ We could also save all the options in a database table, and then run a simple qu
418
418
419
419
```sql
420
420
SELECT ''form'' AS component;
421
-
SELECT * FROM fruit_option;
421
+
SELECT
422
+
''radio'' as type,
423
+
''db'' as name,
424
+
option_name as label,
425
+
option_id as value
426
+
FROM my_options;
422
427
```
423
428
424
-
In this example, depending on what the user clicks, the target `index.sql` page will be loaded with a the variable `$fruit` set to the string "1", "2", or "3".
429
+
In this example, depending on what the user clicks, the page will be reloaded with a the variable `$component` set to the string "form", "map", or "chart".
('form', 'When you want to include some information in the form data, but not display it to the user, you can use a hidden field.
432
437
433
438
This can be used to track simple data such as the current user''s id,
@@ -722,6 +727,8 @@ INSERT INTO parameter(component, name, description, type, top_level, optional) S
722
727
('markdown', 'Set this to the name of a column whose content should be interpreted as markdown . Used to display rich text with links in the table. This argument can be repeated multiple times to intepret multiple columns as markdown.', 'TEXT', TRUE, TRUE),
723
728
('icon', 'Set this to the name of a column whose content should be interpreted as a tabler icon name. Used to display icons in the table. This argument can be repeated multiple times to intepret multiple columns as icons. Introduced in v0.8.0.', 'TEXT', TRUE, TRUE),
724
729
('align_right', 'Name of a column the contents of which should be right-aligned. This argument can be repeated multiple times to align multiple columns to the right. Introduced in v0.15.0.', 'TEXT', TRUE, TRUE),
730
+
('align_center', 'Name of a column the contents of which should be center-aligned. This argument can be repeated multiple times to align multiple columns to the center.', 'TEXT', TRUE, TRUE),
731
+
('monospace', 'Name of a column the contents of which should be displayed in monospace. This argument can be repeated multiple times to display multiple columns in monospace. Introduced in v0.32.1.', 'TEXT', TRUE, TRUE),
725
732
('striped_rows', 'Whether to add zebra-striping to any table row.', 'BOOLEAN', TRUE, TRUE),
726
733
('striped_columns', 'Whether to add zebra-striping to any table column.', 'BOOLEAN', TRUE, TRUE),
727
734
('hover', 'Whether to enable a hover state on table rows.', 'BOOLEAN', TRUE, TRUE),
@@ -754,7 +761,7 @@ INSERT INTO example(component, description, properties) VALUES
754
761
'table',
755
762
'A table with column sorting. Sorting sorts numbers in numeric order, and strings in alphabetical order.',
756
763
json(
757
-
'[{"component":"table", "sort": true, "align_right": ["Price ($)", "Amount in stock"]}, '||
0 commit comments