|
|
| บรรทัดที่ 418: |
บรรทัดที่ 418: |
| {| style="margin-left:20px;" | | {| style="margin-left:20px;" |
| |- style="vertical-align:top;" | | |- style="vertical-align:top;" |
| | style="width:120px;" | '''Parameters''' || | | | style="width:120px;" | '''Parameters''' || ''(See descriptions under [[#String & Text Area Fields]] sub-section)'' |
| * '''form''' ''(FlaskForm-CuneiForm)''
| |
| * '''blank''' ''(Field)''
| |
| * '''track_tb''' ''(str)'': The specification for table-tracking function. This argument takes the format {{code|lang=javascript|'<table_id>:<column_to_track>'}}.
| |
| * '''search''' ''(str)'': The specification for search function. This argument takes the format {{code|lang=javascript|'<search_modal_id>:<lookup_col>'}}. If the search function is meant to fill other fields as well as this field itself, provide '''fill''' argument too. A field with '''search''' argument given is drawn with a ''Search'' button [[ไฟล์:Cuneifox search btn.png|25px|frameless|alt=Search button|Search button]].
| |
| * '''fill''' ''(str)'': The specification for fill function. This argument takes the format {{code|lang=javascript|'<field0>:<col0>,<field1>:<col1>,...'}}; where ''fieldX'' refers to a field within the same form, and ''colX'' refers to a column within the search result.
| |
| * '''expand''' ''(str)'': The specification for form expansion. This argument takes the format {{code|lang=javascript|'<expand_modal_id>:<first_expand_field>'}}. A field with '''expand''' argument given is drawn with an ''Expand'' button [[ไฟล์:Cuneifox formexpand btn.png|25px|frameless|alt=Expand button|Expand button]].
| |
| * '''field_modal''' ''(str)'': The id of the modal holding this field. This value control the showing/hiding for the modal when the field gets or loses focus.
| |
| * '''field_tab''' ''(str)'': The id of the tab holding this field. This value control the navigation to/away from the tab when the field gets or loses focus.
| |
| * '''prepend''' ''(str)'': The string to attach to the left of the field.
| |
| * '''clear_prepend''' ''(bool)'': Whether the HTML element {{code|lang=html|<span>}} holding the '''prepend''' string has a clear background.
| |
| * '''append''' ''(str)'': The string to attach to the right of the field.
| |
| * '''clear_append''' ''(bool)'': Whether the HTML element {{code|lang=html|<span>}} holding the '''append''' string has a clear background.
| |
| * '''label_width''' ''(str: Effective only for fields drawn in slim mode)'': The width of the label {{code|lang=html|<div>}}. The value can be anything interpretable as CSS width, but {{code|lang=css|'<int>px'}} is recommended.
| |
| * '''headless''' ''(bool)'': Whether to draw the label {{code|lang=html|<div>}} at all.
| |
| * '''hidden''' ''(bool)'': Whether the field and the label is drawn but remain invisible. Hidden field is achieved by setting {{code|lang=css|1= display=none}} on the field and label's collective parent {{code|lang=html|<div>}}.
| |
| * '''tabindex''' ''(int)'': The tab-index of the field. This feature is kept open for flexibility; no examples of uses exist at the time of writing.
| |
| * '''pad_bottom''' ''(bool OR {{code|lang=javascript|'default'}})'': Whether the field should have some bottom spacing.
| |
| * '''force_fat''' ''(bool)'': Whether to draw the field in ''fat'' mode regardless of {{code|form.slim}} and {{code|form.subslim}} values.
| |
| * '''force_slim''' ''(bool)'': Whether to draw the field in ''slim'' mode regardless of {{code|form.slim}} and {{code|form.subslim}} values.
| |
| * '''slim_pb''' and '''bunch_pb''' ''(int: 0 ~ 5)'': Set the bottom padding for ''slim'' field. This argument utilizes Bootstrap 4's {{code|lang=css|pb-0}} through {{code|lang=css|pb-5}} classes.
| |
| |} | | |} |
|
| |
|