Use 'subclass' instead of 'class' in ColumnType docs

https://claude.ai/code/session_01SvPEPqHgURTWESRp28pTC3
This commit is contained in:
Claude 2026-03-17 05:22:53 +00:00
commit c73a1c907a
No known key found for this signature in database
2 changed files with 5 additions and 5 deletions

View file

@ -922,7 +922,7 @@ await .get_column_type(database, resource, column)
``column`` - string
The name of the column.
Returns a :ref:`ColumnType <column_types>` instance with ``.config`` populated for the specified column, or ``None`` if no column type is assigned.
Returns a :ref:`ColumnType <column_types>` subclass instance with ``.config`` populated for the specified column, or ``None`` if no column type is assigned.
.. code-block:: python
@ -943,7 +943,7 @@ await .get_column_types(database, resource)
``resource`` - string
The name of the table or view.
Returns a dictionary mapping column names to :ref:`ColumnType <column_types>` instances (with ``.config`` populated) for all columns that have assigned types on the given resource.
Returns a dictionary mapping column names to :ref:`ColumnType <column_types>` subclass instances (with ``.config`` populated) for all columns that have assigned types on the given resource.
.. code-block:: python

View file

@ -503,8 +503,8 @@ Lets you customize the display of values within table cells in the HTML table vi
``request`` - :ref:`internals_request`
The current request object
``column_type`` - :ref:`ColumnType <column_types>` instance or None
The :ref:`ColumnType <column_types>` instance assigned to this column (with ``.config`` populated), or ``None`` if no column type is assigned. You can access ``column_type.name``, ``column_type.config``, etc.
``column_type`` - :ref:`ColumnType <column_types>` subclass instance or None
The :ref:`ColumnType <column_types>` subclass instance assigned to this column (with ``.config`` populated), or ``None`` if no column type is assigned. You can access ``column_type.name``, ``column_type.config``, etc.
If a column has a :ref:`column type <column_types>` assigned and that column type's ``render_cell`` method returns a non-``None`` value, it will take priority over this plugin hook.
@ -999,7 +999,7 @@ The permission system then uses this query along with rules from plugins to dete
register_column_types(datasette)
--------------------------------
Return a list of :ref:`ColumnType <column_types>` **classes** (not instances) to register custom column types. Column types define how values in specific columns are rendered, validated, and transformed.
Return a list of :ref:`ColumnType <column_types>` **subclasses** (not instances) to register custom column types. Column types define how values in specific columns are rendered, validated, and transformed.
.. code-block:: python