Skip to content

Commit

Permalink
[TASK] Merge properties to text - rte page
Browse files Browse the repository at this point in the history
Releases: main, 12.4
  • Loading branch information
linawolf committed Aug 3, 2024
1 parent b507a5f commit 9de9522
Show file tree
Hide file tree
Showing 34 changed files with 393 additions and 307 deletions.
34 changes: 0 additions & 34 deletions Documentation/CodeSnippets/Manual/TypeText9Eval.rst.txt

This file was deleted.

26 changes: 0 additions & 26 deletions Documentation/ColumnsConfig/Type/Text/Default/Examples.rst

This file was deleted.

117 changes: 106 additions & 11 deletions Documentation/ColumnsConfig/Type/Text/Default/Index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,115 @@

.. _columns-text-renderType-default:

==============
text (default)
==============
================
text (multiline)
================

This page describes the :ref:`text <columns-text>` type with no renderType (default).

`type='text'` without a given specific renderType either renders a simple
`<textarea>` or a :ref:`Rich Text field <rich-text-editor-examples>` if
:confval:`text-enableRichtext` is enabled in TCA and
:ref:`page TSconfig <t3tsconfig:pageTsRte>`.

.. contents:: Table of contents:
:local:
:depth: 1

This page describes the :ref:`text <columns-text>` type with no renderType (default).
.. _columns-text-examples:

Examples for multiline text fields
==================================

.. _tca_example_text_4:

Multiline plain text area
-------------------------

.. include:: /Images/Rst/Text4.rst.txt

.. include:: /CodeSnippets/Text4.rst.txt

.. _tca_example_rte_1:

Rich text editor field
----------------------

.. include:: /Images/Rst/Rte1.rst.txt

.. include:: /CodeSnippets/Rte1.rst.txt

.. _columns-text-properties:
.. _columns-text-properties-default:

Properties of the TCA column type `text` with or without enabled rich text
==========================================================================

.. confval-menu::
:display: table
:type:
:Scope:

.. include:: _Properties/_AllowLanguageSynchronization.rst.txt
:show-buttons:

.. include:: _Properties/_Cols.rst.txt
:show-buttons:

.. include:: _Properties/_Default.rst.txt
:show-buttons:

.. include:: _Properties/_EnableRichtext.rst.txt
:show-buttons:

.. include:: _Properties/_EnableTabulator.rst.txt
:show-buttons:

.. include:: _Properties/_Eval.rst.txt
:show-buttons:

.. include:: _Properties/_FieldControl.rst.txt
:show-buttons:

.. include:: _Properties/_FieldInformation.rst.txt
:show-buttons:

.. include:: _Properties/_FieldWizard.rst.txt
:show-buttons:

.. include:: _Properties/_FixedFont.rst.txt
:show-buttons:

.. include:: _Properties/_IsIn.rst.txt
:show-buttons:

.. include:: _Properties/_Max.rst.txt
:show-buttons:

.. include:: _Properties/_Min.rst.txt
:show-buttons:

.. include:: _Properties/_Nullable.rst.txt
:show-buttons:

.. include:: _Properties/_Placeholder.rst.txt
:show-buttons:

.. include:: _Properties/_ReadOnly.rst.txt
:show-buttons:

.. include:: _Properties/_Required.rst.txt
:show-buttons:

.. include:: _Properties/_RichtextConfiguration.rst.txt
:show-buttons:

.. include:: _Properties/_Rows.rst.txt
:show-buttons:

type='text' without a given specific renderType either renders a simple :code:`<textarea>` or a Rich Text
field if Rich Text Editor is enabled in the configuration and for the user.
.. include:: _Properties/_Search.rst.txt
:show-buttons:

.. toctree::
.. include:: _Properties/_Softref.rst.txt
:show-buttons:

Examples
Properties
.. include:: _Properties/_Wrap.rst.txt
:show-buttons:
54 changes: 0 additions & 54 deletions Documentation/ColumnsConfig/Type/Text/Default/Properties.rst

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
.. confval:: behaviour
:name: text-behaviour

.. confval:: allowLanguageSynchronization
:type: boolean
:name: text-behaviour-allowLanguageSynchronization
:Path: $GLOBALS['TCA'][$table]['columns'][$field]['config']['behaviour']['allowLanguageSynchronization']
:Scope: Proc.
:default: false

Allows an editor to select in a localized record whether the value is copied
over from default or source language record, or if the field has an own value
in the localization. If set to true and if the table supports localization
and if a localized record is edited, this setting enables FieldWizard
:ref:`LocalizationStateSelector <columns-input-properties-fieldWizard-localizationStateSelector>`:
Two or three radio buttons shown below the field input. The state of this is
stored in a json encoded array in the database table called :code:`l10n_state`.
It tells the DataHandler which fields of the localization records should be kept
in sync if the underlying default or source record changes.

.. literalinclude:: _Snippets/_AllowLanguageSynchronization.php
:caption: EXT:my_extension/Configuration/TCA/Overrides/someTable.php
Original file line number Diff line number Diff line change
@@ -1,27 +1,17 @@
.. include:: /Includes.rst.txt
.. _columns-text-properties-cols:

====
cols
====

.. confval:: cols
:name: text-cols
:Path: $GLOBALS['TCA'][$table]['columns'][$field]['config']
:type: integer
:Scope: Display


:RenderType: :ref:`textTable <columns-text-renderType-textTable>`,
:ref:`default <columns-text-renderType-default>`

Abstract value for the width of the :code:`<textarea>` field. To set the textarea to the full width
of the form area, use the value 50. Default is 30.
Abstract value for the width of the :code:`<textarea>` field. To set
the textarea to the full width of the form area, use the value 50. Default is 30.

Does not apply to RTE fields.

A simple text editor with 20 width
==================================
.. rubric:: Example: A simple text editor with 20 width

.. include:: /Images/Rst/Text4.rst.txt

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.. confval:: default
:name: text-default
:Path: $GLOBALS['TCA'][$table]['columns'][$field]['config']['default']
:type: string
:Scope: Display / Proc.

Default value set if a new record is created.
Original file line number Diff line number Diff line change
@@ -1,25 +1,17 @@
.. include:: /Includes.rst.txt
.. _columns-text-properties-enableRichtext:

==============
enableRichtext
==============

.. confval:: enableRichtext
:name: text-enableRichtext
:Path: $GLOBALS['TCA'][$table]['columns'][$field]['config']
:type: boolean
:Scope: Display / Proc.
:RenderType: :ref:`default <columns-text-renderType-default>`

If set to true, the system renders a Rich Text Editor if that is enabled for the editor (default: yes),
and if a suitable editor extension is loaded (default: rteckeditor).

If either of these requirements is not met, the system falls back to a :code:`<textarea>` field.


Rich text editor (RTE)
======================
.. rubric:: Example: Rich text editor (RTE)

.. include:: /Images/Rst/Rte1.rst.txt

Expand Down
Original file line number Diff line number Diff line change
@@ -1,29 +1,20 @@
.. include:: /Includes.rst.txt
.. _columns-text-properties-enableTabulator:

===============
enableTabulator
===============

.. confval:: enableTabulator
:name: text-enableTabulator
:Path: $GLOBALS['TCA'][$table]['columns'][$field]['config']
:type: boolean
:Scope: Display
:RenderType: :ref:`default <columns-text-renderType-default>`, :ref:`textTable <columns-text-renderType-textTable>`

Enabling this allows to use tabs in a text field. This works well together with
:ref:`fixed-width fonts <columns-text-properties-fixedFont>` (monospace) for code editing.
:ref:`fixed-width fonts <columns-text-properties-fixedFont>` (monospace)
for code editing.

Does not apply to RTE fields.

Examples
========

.. _tca_example_text_15:

Fixed font field with tabulators enabled
----------------------------------------
.. rubric:: Example: Fixed font field with tabulators enabled

.. include:: /Images/Rst/Text15.rst.txt

Expand Down
Loading

0 comments on commit 9de9522

Please sign in to comment.