Page with elements

Just about every page element on a single page

This page demonstrates styles and widgets used for the YugabyteDB Documentation site. To view the source for the file, click Contribute and choose Edit this page.

Tab widgets

This is a top-level tab widget, that uses different files for each tab. Everything that follows is in this tab's file. If you change tabs, you get a whole new page.

Second tab widget style

This is a second-level tab widget, that uses different files for each tab - same as the one above, just styled differently.

Everything that follows is in this tab's file. If you change tabs, you get a whole new page.

In-page tab widget

This tab widget doesn't use separate files to fill in the content and then link between. Here the content is placed inside the tabpane shortcode.

Another tab style; here all the tab contents are in-page.

Headings inside this widget don't show up in RightNav

To build and run the application, do the following:

  1. Clone the sample application to your computer:

    git clone https://github.com/YugabyteDB-Samples/yugabyte-simple-java-app.git && cd yugabyte-simple-java-app
    
  2. Provide connection parameters.

    The application needs to establish a connection to the YugabyteDB cluster. To do this:

    • Set the following connection parameters:

      • host - the host name of your YugabyteDB cluster. To obtain a YugabyteDB Managed cluster host name, sign in to YugabyteDB Managed, select your cluster on the Clusters page, and click Settings. The host is displayed under Connection Parameters.
      • port - the port number that will be used by the JDBC driver (the default YugabyteDB YSQL port is 5433).
    • Save the file.

The end of this tab.

The contents of the next tab. You can keep adding tabs in similar fashion.

Headings inside this widget don't show up in RightNav

To build and run the application, do the following:

  1. Clone the sample application to your computer:

    git clone https://github.com/YugabyteDB-Samples/yugabyte-simple-go-app.git && cd yugabyte-simple-go-app
    
  2. Provide connection parameters.

Pills

These pills automatically re-flow based on page width; just keep adding list items. Use these pills for landing pages or as an alternative to tabs.

Table

The following is a basic markdown table.

Table A column
A row Another column in a table. Maybe to describe stuff. Might have bulleted lists etc, but that all has to be done using HTML.
Another row Another row in a table.
Another row Another column in a table.

Notes and blockquote

An ordinary paragraph.

Blockquote

Blockquote text

Some more blockquote text.

Note

This is an actual Note. Pay special attention to this thing, maybe.

Tip

This is an actual Tip. Maybe there's a cool alternative to what you are doing.

Warning

This is an actual Warning. Whatever you are doing may threaten your data if you do it wrong.

Images and video

What follows is an image:

Connect using cloud shell

What follows is an embedded YouTube video:

Lists

What follows are some numbered steps, some code, text indented under a step:

  1. Numbered list with indented lists.

    1. Second level numbered list indent.

    2. Second level numbered list indent.

      1. Third level numbered list indent.

      2. Third level numbered list indent.

  2. Second list item. Some text in bold. Some text in italics.

  3. Third list item.

    Indented text under a list.

    Some code
    
  4. Fourth list item.

Bulleted lists with levels of indent:

  • Bulleted list with indented lists.

    • Second level Bulleted list indent.

    • Second level Bulleted list indent.

      • Third level Bulleted list indent.

      • Third level Bulleted list indent.

Heading 3

Heading 4

Some bullets:

  • a cluster deployed in YugabyteDB Managed.
  • the cluster CA certificate; YugabyteDB Managed uses TLS to secure connections to the database.
  • your computer added to the cluster IP allow list.

Refer to Before you begin.

Glossary entries

Glossary term
Definition. This text is a definition for a glossary term, or any sort of definition list.
Glossary term
Definition. This text is a definition for a glossary term, or any sort of definition list.
Another paragraph in the definition.
Glossary term
Definition. This text is a definition for a glossary term, or any sort of definition list.
Another paragraph in the definition.

Details tag

The details HTML tag is used to create an interactive widget that the user can open and close. By default, the widget is closed. When open, it expands, and displays the contents.

Long code block

These contents might be a very long bit of code or somesuch.

Syntax documentation

ysqlsh [ <option>...] [ <dbname> [ <username> ]]

Horizontal rule

Once in awhile, there is a horizontal rule.


Flags

Flags are documented often using a heading 5.

heading 5

Heading 5 doesn't show up in right navigation. We probably wouldn't want it to, as there can be dozens of these flags on some pages.

Heading 5 is used so that we can deep-link to the flag.

-F, --this-is-a-flag

This is a paragraph.

Included file

This content is included from a separate file (called, in this case, include-file.md) using a readfile shortcode.

Headings in read files do not appear in the right navigation.

Another heading in the included file

Use readfile to add repetitive text to multiple pages.

Included markdown

This content is included from a separate file (called, in this case, include-markdown.md) using an includeMarkdown shortcode.

Headings in included markdown files do appear in the right navigation.

Another heading in the included markdown

Use includeMarkdown to add repetitive text to multiple pages.

API diagrams

API docs have Grammar/Diagram pairs. They use a special code (ebnf) to display the appropriate grammar and diagrams.

copy_from ::= COPY table_name [ ( column_name [ , ... ] ) ]  FROM 
              { 'filename' | PROGRAM 'command' | STDIN }  
              [ [ WITH ] ( copy_option [ , ... ] ) ]

copy_to ::= COPY { table_name [ ( column_names ) ] | subquery }  TO 
            { 'filename' | PROGRAM 'command' | STDOUT }  
            [ [ WITH ] ( copy_option [ , ... ] ) ]

copy_option ::= FORMAT format_name
                | OIDS [ boolean ]
                | FREEZE [ boolean ]
                | DELIMITER 'delimiter_character'
                | NULL 'null_string'
                | HEADER [ boolean ]
                | QUOTE 'quote_character'
                | ESCAPE 'escape_character'
                | FORCE_QUOTE { ( column_names ) | * }
                | FORCE_NOT_NULL ( column_names )
                | FORCE_NULL ( column_names )
                | ENCODING 'encoding_name'
                | ROWS_PER_TRANSACTION int_literal
                | DISABLE_FK_CHECK
                | REPLACE
                | SKIP int_literal

copy_from

COPYtable_name(,column_name)FROMfilenamePROGRAMcommandSTDINWITH(,copy_option)

copy_to

COPYtable_name(column_names)subqueryTOfilenamePROGRAMcommandSTDOUTWITH(,copy_option)

copy_option

FORMATformat_nameOIDSbooleanFREEZEbooleanDELIMITERdelimiter_characterNULLnull_stringHEADERbooleanQUOTEquote_characterESCAPEescape_characterFORCE_QUOTE(column_names)*FORCE_NOT_NULL(column_names)FORCE_NULL(column_names)ENCODINGencoding_nameROWS_PER_TRANSACTIONint_literalDISABLE_FK_CHECKREPLACESKIPint_literal