snapshot of https://github.com/mattermost/mattermost.git (master, 2026-09-16; blobs > 131072B omitted)
Some checks failed
Server CI / Postgres (shard 0) (push) Has been skipped
Server CI / Postgres (shard 3) (push) Has been skipped
BuildEnv Docker Image / build-image (push) Failing after 4s
BuildEnv Docker Image / build-image-fips (push) Failing after 4s
Migration Review & Release Notes / Generate migration review & release notes (push) Failing after 3s
Server CI / Build Environment (push) Failing after 3s
Server CI / Postgres (shard 1) (push) Has been skipped
Tools CI / check-style (mattermost-govet) (push) Failing after 4s
Server CI / Postgres (shard 2) (push) Has been skipped
Tools CI / check-style (mmgotool) (push) Failing after 3s
Server CI / Elasticsearch v8 Compatibility (push) Has been skipped
Server CI / OpenSearch v2 Compatibility (push) Has been skipped
Server CI / Postgres FIPS (shard 0) (push) Has been skipped
Tools CI / Test (mattermost-govet) (push) Failing after 3s
Server CI / Postgres FIPS (shard 1) (push) Has been skipped
Server CI / Postgres FIPS (shard 2) (push) Has been skipped
Tools CI / Test (mmgotool) (push) Failing after 3s
Server CI / Postgres FIPS (shard 3) (push) Has been skipped
Server CI / Run mmctl tests (push) Has been skipped
Server CI / Run mmctl tests (FIPS) (push) Has been skipped
Server CI / Merge Postgres Test Results (push) Has been skipped
Server CI / Merge Postgres FIPS Test Results (push) Has been skipped
Server CI / Check backport migrations (push) Has been skipped
Server CI / Check generated files (push) Has been skipped
Server CI / check-style (push) Has been skipped
Server CI / Vet API (push) Has been skipped
Server CI / Build mattermost server app (push) Has been skipped
Server CI / Server CI Complete (push) Failing after 2s
Server CI / Server CI Artifacts (push) Has been skipped
Server CI / Sentry Upload (push) Has been skipped
Server CI / Server CI Report (push) Failing after 5m1s
Server CI Nightly Race / Race Detector (push) Has been skipped
CodeQL / Analyze (go) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
Webapp CI Cache Warm / Warm Webapp node_modules Cache (push) Has been cancelled
E2E CI Cache Warm / Warm E2E npm Registry Cache (push) Has been cancelled
API / build (push) Has been cancelled
Web App CI / check-types (push) Has been cancelled
Web App CI / check-lint (push) Has been cancelled
Web App CI / check-i18n (push) Has been cancelled
Web App CI / check-external-links (push) Has been cancelled
Web App CI / test (platform) (push) Has been cancelled
Web App CI / test (mattermost-redux) (push) Has been cancelled
Web App CI / test (channels shard 1/4) (push) Has been cancelled
Web App CI / test (channels shard 2/4) (push) Has been cancelled
Web App CI / test (channels shard 3/4) (push) Has been cancelled
Web App CI / test (channels shard 4/4) (push) Has been cancelled
Web App CI / upload-coverage (push) Has been cancelled
Web App CI / build (push) Has been cancelled
YAML Lint / yamllint (push) Has been cancelled
Push mirrored docker images / cd/Push mirrored docker images (push) Has been cancelled
docs-cd / Build and deploy docs (push) Has been cancelled
Docs CI / build (push) Has been cancelled
E2E Cache Warm: Cypress deps / Warm Cypress deps cache (push) Has been cancelled
Scorecards supply-chain security / Scorecard analysis (push) Has been cancelled
Server CI Weekly / Postgres FIPS (push) Has been skipped
Server CI Weekly / Run mmctl tests (FIPS) (push) Has been skipped
Server CI Weekly / Postgres with binary parameters (push) Has been skipped
Server CI Weekly / Build Environment (push) Failing after 1s
Server CI Cache Warm / Warm Go Module and Build Cache (push) Failing after 2s
Server CI Nightly Race / Build Environment (push) Failing after 1s
Some checks failed
Server CI / Postgres (shard 0) (push) Has been skipped
Server CI / Postgres (shard 3) (push) Has been skipped
BuildEnv Docker Image / build-image (push) Failing after 4s
BuildEnv Docker Image / build-image-fips (push) Failing after 4s
Migration Review & Release Notes / Generate migration review & release notes (push) Failing after 3s
Server CI / Build Environment (push) Failing after 3s
Server CI / Postgres (shard 1) (push) Has been skipped
Tools CI / check-style (mattermost-govet) (push) Failing after 4s
Server CI / Postgres (shard 2) (push) Has been skipped
Tools CI / check-style (mmgotool) (push) Failing after 3s
Server CI / Elasticsearch v8 Compatibility (push) Has been skipped
Server CI / OpenSearch v2 Compatibility (push) Has been skipped
Server CI / Postgres FIPS (shard 0) (push) Has been skipped
Tools CI / Test (mattermost-govet) (push) Failing after 3s
Server CI / Postgres FIPS (shard 1) (push) Has been skipped
Server CI / Postgres FIPS (shard 2) (push) Has been skipped
Tools CI / Test (mmgotool) (push) Failing after 3s
Server CI / Postgres FIPS (shard 3) (push) Has been skipped
Server CI / Run mmctl tests (push) Has been skipped
Server CI / Run mmctl tests (FIPS) (push) Has been skipped
Server CI / Merge Postgres Test Results (push) Has been skipped
Server CI / Merge Postgres FIPS Test Results (push) Has been skipped
Server CI / Check backport migrations (push) Has been skipped
Server CI / Check generated files (push) Has been skipped
Server CI / check-style (push) Has been skipped
Server CI / Vet API (push) Has been skipped
Server CI / Build mattermost server app (push) Has been skipped
Server CI / Server CI Complete (push) Failing after 2s
Server CI / Server CI Artifacts (push) Has been skipped
Server CI / Sentry Upload (push) Has been skipped
Server CI / Server CI Report (push) Failing after 5m1s
Server CI Nightly Race / Race Detector (push) Has been skipped
CodeQL / Analyze (go) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
Webapp CI Cache Warm / Warm Webapp node_modules Cache (push) Has been cancelled
E2E CI Cache Warm / Warm E2E npm Registry Cache (push) Has been cancelled
API / build (push) Has been cancelled
Web App CI / check-types (push) Has been cancelled
Web App CI / check-lint (push) Has been cancelled
Web App CI / check-i18n (push) Has been cancelled
Web App CI / check-external-links (push) Has been cancelled
Web App CI / test (platform) (push) Has been cancelled
Web App CI / test (mattermost-redux) (push) Has been cancelled
Web App CI / test (channels shard 1/4) (push) Has been cancelled
Web App CI / test (channels shard 2/4) (push) Has been cancelled
Web App CI / test (channels shard 3/4) (push) Has been cancelled
Web App CI / test (channels shard 4/4) (push) Has been cancelled
Web App CI / upload-coverage (push) Has been cancelled
Web App CI / build (push) Has been cancelled
YAML Lint / yamllint (push) Has been cancelled
Push mirrored docker images / cd/Push mirrored docker images (push) Has been cancelled
docs-cd / Build and deploy docs (push) Has been cancelled
Docs CI / build (push) Has been cancelled
E2E Cache Warm: Cypress deps / Warm Cypress deps cache (push) Has been cancelled
Scorecards supply-chain security / Scorecard analysis (push) Has been cancelled
Server CI Weekly / Postgres FIPS (push) Has been skipped
Server CI Weekly / Run mmctl tests (FIPS) (push) Has been skipped
Server CI Weekly / Postgres with binary parameters (push) Has been skipped
Server CI Weekly / Build Environment (push) Failing after 1s
Server CI Cache Warm / Warm Go Module and Build Cache (push) Failing after 2s
Server CI Nightly Race / Build Environment (push) Failing after 1s
This commit is contained in:
691
docs/main/end-user-guide/collaborate/format-messages.mdx
Normal file
691
docs/main/end-user-guide/collaborate/format-messages.mdx
Normal file
@@ -0,0 +1,691 @@
|
||||
---
|
||||
title: "Format messages"
|
||||
---
|
||||
import useBaseUrl from '@docusaurus/useBaseUrl';
|
||||
import Tabs from '@theme/Tabs';
|
||||
import TabItem from '@theme/TabItem';
|
||||
|
||||
<PlanAvailability slug="all-commercial" />
|
||||
|
||||
## Use the messaging formatting toolbar
|
||||
|
||||
From Mattermost v7.0, you can format your messages in Mattermost using the message formatting toolbar without having to specify any Markdown syntax.
|
||||
|
||||

|
||||
|
||||
The message formatting toolbar offers the following formatting options:
|
||||
|
||||
<table>
|
||||
<colgroup>
|
||||
<col style={{width: '53%'}} />
|
||||
<col style={{width: '46%'}} />
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Formatting option</th>
|
||||
<th>Icon</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><a href="#use-markdown">Bold, italicize, or strike out text</a></td>
|
||||
<td>
|
||||
<img src={useBaseUrl('/img/ui/format-bold_F0264.svg')} alt="Bold" className="theme-icon" />
|
||||
<img src={useBaseUrl('/img/ui/format-italic_F0277.svg')} alt="Italicize" className="theme-icon" />
|
||||
<img src={useBaseUrl('/img/ui/format-strikethrough-variant_F0281.svg')} alt="Strikeout" className="theme-icon" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Add <a href="#headings">headings</a>, <a href="#links">links</a>, or attachments</td>
|
||||
<td>
|
||||
<img src={useBaseUrl('/img/ui/format-header_E81D.svg')} alt="Headings" className="theme-icon" />
|
||||
<img src={useBaseUrl('/img/ui/link-variant_F0339.svg')} alt="Copy link" className="theme-icon" />
|
||||
<img src={useBaseUrl('/img/ui/paperclip_F03E2.svg')} alt="Attachments" className="theme-icon" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Format a numbered list, a bulleted list, quoted text, or text as code</td>
|
||||
<td>
|
||||
<img src={useBaseUrl('/img/ui/format-list-numbered_F027B.svg')} alt="Numbered list" className="theme-icon" />
|
||||
<img src={useBaseUrl('/img/ui/format-list-bulleted_F0279.svg')} alt="Bulleted list" className="theme-icon" />
|
||||
<img src={useBaseUrl('/img/ui/format-quote-open_F0757.svg')} alt="Quoted text" className="theme-icon" />
|
||||
<img src={useBaseUrl('/img/ui/code-tags_F0174.svg')} alt="Code" className="theme-icon" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2"><a href="/end-user-guide/collaborate/react-with-emojis-gifs">Add emojis or GIFs</a> <img src={useBaseUrl('/img/ui/emoticon-outline_F01F2.svg')} alt="Emoji" className="theme-icon" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2"><a href="/end-user-guide/collaborate/message-priority">Set message priority</a> <img src={useBaseUrl('/img/ui/alert-circle-outline_F05D6.svg')} alt="Message priority" className="theme-icon" /></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
Review how your message formatting will look when the message is sent by selecting the **Show/Hide Preview** <img src={useBaseUrl('/img/ui/eye-outline_F06D0.svg')} alt="Review your message text formatting using the Show/Hide preview icon in the message formatting toolbar." className="theme-icon" /> icon. Return to your draft message by selecting the icon again.
|
||||
|
||||
<Tip>
|
||||
|
||||
- Hide the formatting options by selecting the **Show/Hide Formatting** <img src={useBaseUrl('/img/ui/format-letter-case_F0B34.svg')} alt="Hide formatting options in the message formatting toolbar using the Show/Hide Formatting icon." className="theme-icon" /> icon. Select the icon again to show the formatting options.
|
||||
- You can control whether post formatting is rendered within the message formatting editor. When disabled, raw text is shown. See the [Channels customization](/end-user-guide/preferences/manage-advanced-options) documentation for details.
|
||||
|
||||
</Tip>
|
||||
|
||||
## Use Markdown
|
||||
|
||||
You can also format your messages in Mattermost using Markdown to control [text styling](#text-style), [links](#links), [headings](#headings), [lists](#lists), [code blocks](#code-blocks), [in-line code](#in-line-code), [in-line images](#in-line-images), [horizontal lines](#horizontal-lines), [block quotes](#block-quotes), [tables](#tables), and [math formulas](#math-formulas). Markdown makes it easy to format messages: type a message as you normally would, then use formatting syntax to render the message a specific way. For a guide to using Markdown in Mattermost, [see this blog post](https://mattermost.com/blog/laymans-guide-to-markdown-on-mattermost/).
|
||||
|
||||

|
||||
|
||||
### Text style
|
||||
|
||||
You can use either `_` or `*` around a word or phrase to make it italic, or `__` or `**` around a word or phrase to make it bold.
|
||||
|
||||
<Tip>
|
||||
|
||||
Common formatting keyboard shortcuts are supported. Bold text by pressing <kbd>Ctrl</kbd> <kbd>B</kbd> on Windows and Linux, or <kbd>⌘</kbd> <kbd>B</kbd> on Mac. Italicize text by pressing <kbd>Ctrl</kbd> <kbd>I</kbd> on Windows or Linux, or <kbd>⌘</kbd> <kbd>I</kbd> on Mac.
|
||||
|
||||
</Tip>
|
||||
|
||||
- `*italics*` (or `_italics_`) renders as *italics*
|
||||
- `**bold**` renders as **bold**
|
||||
- `***bold-italic***` renders as <img src={useBaseUrl('/images/bold_italics.png')} width="100" alt="Bold Italics" />
|
||||
- `~~strikethrough~~` renders as <img src={useBaseUrl('/images/strikethrough.png')} width="100" alt="Strike Through" />
|
||||
|
||||
### Links
|
||||
|
||||
<Tip>
|
||||
|
||||
Format selected message text as a link by pressing <kbd>Ctrl</kbd> <kbd>K</kbd> on Windows and Linux, or by pressing <kbd>⌘</kbd> <kbd>K</kbd> on Mac.
|
||||
|
||||
</Tip>
|
||||
|
||||
#### Channel links
|
||||
|
||||
Create a link to a public channel in a message by typing `~` followed by the channel name (e.g. `~roadmap`). Channel members see private channel names returned.
|
||||
|
||||
#### Labeled links
|
||||
|
||||
Create labeled links by putting the desired text in square brackets `[ ]` and the associated link in round brackets `( )`.
|
||||
|
||||
`[Check out Mattermost!](https://.mattermost.com/)`
|
||||
|
||||
Renders as: [Check out Mattermost!](https://mattermost.com/)
|
||||
|
||||
### Headings
|
||||
|
||||
Make a heading by typing `#` and a space before your title. For smaller headings, use more `#`'s.
|
||||
|
||||
``` text
|
||||
## Large Heading
|
||||
### Smaller Heading
|
||||
#### Even Smaller Heading
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||

|
||||
|
||||
Alternatively, you can underline the text using equal signs `===` or hyphens `---` to create headings.
|
||||
|
||||
``` text
|
||||
Large Heading
|
||||
-------------
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||

|
||||
|
||||
### Lists
|
||||
|
||||
Create a list by using asterisks `*`, hyphens `-`, and/or plus signs `+` interchangeably as bullets. Indent bullet points by adding two spaces in front each one.
|
||||
|
||||
``` text
|
||||
* item one
|
||||
- item two
|
||||
+ item two sub-point
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||
- item one
|
||||
- item two
|
||||
- item two sub-point
|
||||
|
||||
Make an ordered list by using numbers instead:
|
||||
|
||||
``` text
|
||||
1. Item one
|
||||
1. Item two
|
||||
1. item three
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||
1. Item one
|
||||
2. Item two
|
||||
3. Item three
|
||||
|
||||
You can also start a list at any number:
|
||||
|
||||
``` text
|
||||
4. The first list number is 4.
|
||||
1. The second list number is 5.
|
||||
1. The third list number is 6.
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||
4. The first list number is 4.
|
||||
5. The second list number is 5.
|
||||
6. The third list number is 6.
|
||||
|
||||
Make a task list by including square brackets `[ ]`. Mark a task as complete by adding an `x`.
|
||||
|
||||
``` text
|
||||
- [ ] Item one
|
||||
- [ ] Item two
|
||||
- [x] Completed item
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||

|
||||
|
||||
### Code blocks
|
||||
|
||||
Creating a fixed-width code block is recommended for pasting multi-line blocks of code or other text output because it's easier to read with fixed-width font alignment. Examples include block text snippets, ASCII tables, and log files. Rendered code blocks include a **Copy** option to copy the contents of the code block.
|
||||
|
||||
This can be accomplished by placing three backticks (```` ``` ````) on the line directly above and directly below your code:
|
||||
|
||||
````text
|
||||
```
|
||||
this is my
|
||||
code block
|
||||
```
|
||||
````
|
||||
|
||||
<Tip>
|
||||
|
||||
Type three backticks (```` ``` ````), press <kbd>Shift</kbd> <kbd>Enter</kbd> on Windows or Linux, or <kbd>⇧</kbd> <kbd>↵</kbd> on Mac, `<type_your_code>`, press <kbd>Shift</kbd> <kbd>Enter</kbd> on Windows or Linux, or <kbd>⇧</kbd> <kbd>↵</kbd> on Mac again, then type three more backticks (```` ``` ````).
|
||||
|
||||
</Tip>
|
||||
|
||||
Or by indenting each line by four spaces:
|
||||
|
||||
```text
|
||||
this is my
|
||||
code block
|
||||
```
|
||||
|
||||
### Syntax highlighting
|
||||
|
||||
To add syntax highlighting, type the language to be highlighted after the ```` ``` ```` at the beginning of the code block. Mattermost also offers four different code themes (GitHub, Solarized Dark, Solarized Light, and Monokai) that can be changed in **Settings \> Display \> Theme \> Custom Theme \> Center Channel Styles**.
|
||||
|
||||
Supported languages and their aliases include:
|
||||
|
||||
<table width="100%" border="1" cellpadding="5px" style={{marginBottom: '20px'}}>
|
||||
<tr class="row-odd">
|
||||
<th class="head">Language</th>
|
||||
<th class="head">Aliases</th>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">ActionScript</td>
|
||||
<td valign="middle">actionscript, as, as3</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">AppleScript</td>
|
||||
<td valign="middle">applescript</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Bash</td>
|
||||
<td valign="middle">bash, sh</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Clojure</td>
|
||||
<td valign="middle">clojure</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">CoffeeScript</td>
|
||||
<td valign="middle">coffescript, coffee, coffee-script</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">C/C++</td>
|
||||
<td valign="middle">cpp, c++, c</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">C#</td>
|
||||
<td valign="middle">cs, c#, csharp</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">CSS</td>
|
||||
<td valign="middle">css</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">D</td>
|
||||
<td valign="middle">d, dlang</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Dart</td>
|
||||
<td valign="middle">dart</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Delphi</td>
|
||||
<td valign="middle">delphi</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Diff</td>
|
||||
<td valign="middle">diff, patch, udiff</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Django</td>
|
||||
<td valign="middle">django</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Dockerfile</td>
|
||||
<td valign="middle">dockerfile, docker</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Elixir</td>
|
||||
<td valign="middle">elixir, ex, exs</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Erlang</td>
|
||||
<td valign="middle">erlang, erl</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Fortran</td>
|
||||
<td valign="middle">fortran</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">F#</td>
|
||||
<td valign="middle">fsharp</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">G-Code</td>
|
||||
<td valign="middle">gcode</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Go</td>
|
||||
<td valign="middle">go, golang</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Groovy</td>
|
||||
<td valign="middle">groovy</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Handlebars</td>
|
||||
<td valign="middle">handlebars, hbs, mustache</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Haskell</td>
|
||||
<td valign="middle">haskell, hs</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Haxe</td>
|
||||
<td valign="middle">haxe</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Java</td>
|
||||
<td valign="middle">java</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">JavaScript</td>
|
||||
<td valign="middle">javascript, js</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">JSON</td>
|
||||
<td valign="middle">json</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Julia</td>
|
||||
<td valign="middle">julia, jl</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Kotlin</td>
|
||||
<td valign="middle">kotlin</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">LaTeX</td>
|
||||
<td valign="middle">latex, tex</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Less</td>
|
||||
<td valign="middle">less</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Lisp</td>
|
||||
<td valign="middle">lisp</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Lua</td>
|
||||
<td valign="middle">lua</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Makefile</td>
|
||||
<td valign="middle">makefile, make, mf, gnumake, bsdmake</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Markdown</td>
|
||||
<td valign="middle">markdown, md, mkd</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Matlab</td>
|
||||
<td valign="middle">matlab, m</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Objective C</td>
|
||||
<td valign="middle">objectivec, objective_c, objc</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">OCaml</td>
|
||||
<td valign="middle">ocaml</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Perl</td>
|
||||
<td valign="middle">perl, pl</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Pascal</td>
|
||||
<td valign="middle">pascal, pas</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">PostgreSQL</td>
|
||||
<td valign="middle">pgsql, postgres, postgresql</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">PHP</td>
|
||||
<td valign="middle">php, php3, php4, php5</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">PowerShell</td>
|
||||
<td valign="middle">powershell, posh</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Puppet</td>
|
||||
<td valign="middle">puppet, pp</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Python</td>
|
||||
<td valign="middle">python, py</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">R</td>
|
||||
<td valign="middle">r, s</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Ruby</td>
|
||||
<td valign="middle">ruby, rb</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Rust</td>
|
||||
<td valign="middle">rust, rs</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Scala</td>
|
||||
<td valign="middle">scala</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Scheme</td>
|
||||
<td valign="middle">scheme</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">SCSS</td>
|
||||
<td valign="middle">scss</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Smalltalk</td>
|
||||
<td valign="middle">smalltalk, st, squeak</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">SQL</td>
|
||||
<td valign="middle">sql</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Stylus</td>
|
||||
<td valign="middle">stylus, styl</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Swift</td>
|
||||
<td valign="middle">swift</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Text</td>
|
||||
<td valign="middle">text</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">TypeScript</td>
|
||||
<td valign="middle">typescript, ts, tsx</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">VB.Net</td>
|
||||
<td valign="middle">vbnet, vb, visualbasic</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">VBScript</td>
|
||||
<td valign="middle">vbscript</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">Verilog</td>
|
||||
<td valign="middle">verilog</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">VHDL</td>
|
||||
<td valign="middle">vhdl</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">HTML, XML</td>
|
||||
<td valign="middle">html, xml</td>
|
||||
</tr>
|
||||
<tr class="row-odd">
|
||||
<td valign="middle">YAML</td>
|
||||
<td valign="middle">yaml, yml</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
Example:
|
||||
|
||||
```` text
|
||||
``` go
|
||||
package main
|
||||
import "fmt"
|
||||
func main() {
|
||||
fmt.Println("Hello, 世界")
|
||||
}
|
||||
```
|
||||
````
|
||||
|
||||
Renders as:
|
||||
|
||||
**GitHub Theme**
|
||||
|
||||

|
||||
|
||||
**Solarized Dark Theme**
|
||||
|
||||

|
||||
|
||||
**Solarized Light Theme**
|
||||
|
||||

|
||||
|
||||
**Monokai Theme**
|
||||
|
||||

|
||||
|
||||
### In-line code
|
||||
|
||||
Create in-line monospaced code text by surrounding it with backticks ``<code>. Don't use single quotes </code><code>'</code>\`.
|
||||
|
||||
``` text
|
||||
`monospace`
|
||||
```
|
||||
|
||||
Renders as: `monospace`.
|
||||
|
||||
### In-line images
|
||||
|
||||
In-line images are images added within lines of text. You can control whether all in-line images over 100px in height are automatically collapsed or expanded in messages by setting a [user preference](/end-user-guide/preferences/manage-your-display-options), or by using the `/collapse` and `/expand` slash commands.
|
||||
|
||||
To add in-line images to text, use an exclamation mark `!` followed by the `alt text` in square brackets `[ ]`, then the `image URL` in round brackets `( )`. You can add hover text after the link by placing the text in quotes `" "`.
|
||||
|
||||
Example:
|
||||
|
||||
``` text
|
||||

|
||||
```
|
||||
|
||||
If the height of the original image is more than 500 pixels, Mattermost sets the image height at 500 pixels and adjusts the width to maintain the original aspect ratio.
|
||||
|
||||
You can set the width and height of the displayed image after the URL of the image by using an equals sign `=` followed by values for both width and height `##x##`. If you set only the width, Mattermost adjusts the height to maintain the original aspect ratio.
|
||||
|
||||
<Warning>
|
||||
|
||||
The native apps do not support fixed width and height and will display the full-size image.
|
||||
|
||||
</Warning>
|
||||
|
||||
Examples:
|
||||
|
||||
``` text
|
||||
.. |mattermost-icon-76x76| image:: ../images/icon-76x76.png
|
||||
.. |mattermost-icon-50x76| image:: ../images/icon-50x76.png
|
||||
```
|
||||
|
||||
#### In-line image with hover text
|
||||
|
||||
``` text
|
||||

|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||
> 
|
||||
|
||||
#### In-line image with link
|
||||
|
||||
<Note>
|
||||
|
||||
An extra set of square brackets `[ ]` is required around the alt text, and round brackets `( )` are required around the image link.
|
||||
|
||||
</Note>
|
||||
|
||||
``` text
|
||||
[](https://github.com/mattermost/mattermost)
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||
> [](https://github.com/mattermost/mattermost)
|
||||
|
||||
#### In-line image displayed with fixed width and height
|
||||
|
||||
Example: An in-line image that's 50 pixels wide and 76 pixels high.
|
||||
|
||||
``` text
|
||||

|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||
> <img src={useBaseUrl('/images/icon-50x76.png')} id="Mattermost Icon" alt="Mattermost" />
|
||||
|
||||
#### In-line image displayed with fixed width
|
||||
|
||||
Example: An in-line image that's 50 pixels wide where the system adjusts the height to maintain the original aspect ratio.
|
||||
|
||||
``` text
|
||||

|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||
> <img src={useBaseUrl('/images/icon-76x76.png')} width="50" alt="Mattermost" />
|
||||
|
||||
### Horizontal lines
|
||||
|
||||
Create a line by using three `*`, `_`, or `-`.
|
||||
|
||||
`***`
|
||||
|
||||
Renders as:
|
||||
|
||||
------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
### Block quotes
|
||||
|
||||
Create block quotes using `>`.
|
||||
|
||||
`> block quotes` renders as:
|
||||
|
||||

|
||||
|
||||
### Tables
|
||||
|
||||
Create a table by placing a dashed line `---` under the header row, then separating each column with using pipes `|`. The columns don’t need to line up exactly. Choose how to align table columns by including colons `:` within the header row.
|
||||
|
||||
``` text
|
||||
| Left-Aligned | Center Aligned | Right Aligned |
|
||||
| :------------ |:---------------:| -----:|
|
||||
| Left column 1 | this text | $100 |
|
||||
| Left column 2 | is | $10 |
|
||||
| Left column 3 | centered | $1 |
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||

|
||||
|
||||
<Note>
|
||||
|
||||
Multi-line text in a table cell isn't supported using HTML tags such as `<br />` or `<br/>`.
|
||||
|
||||
</Note>
|
||||
|
||||
### Math Formulas
|
||||
|
||||
<Tabs>
|
||||
<TabItem value="using-inline-latex" label="Using Inline LaTeX">
|
||||
|
||||
You can create formulas that display inline using LaTeX. Use the dollar sign ($) symbol at the beginning and end of each formula.
|
||||
|
||||
<Note>
|
||||
|
||||
This feature is [disabled by default](/administration-guide/configure/site-configuration-settings#enable-inline-latex-rendering). Contact your system admin to enable this setting in **System Console \> Site Configuration \> Posts** to use this feature.
|
||||
|
||||
</Note>
|
||||
|
||||
``` text
|
||||
$X_k = \sum_{n=0}^{2N-1} x_n \cos \left[\frac{\pi}{N} \left(n+\frac{1}{2}+\frac{N}{2}\right) \left(k+\frac{1}{2}\right) \right]$
|
||||
```
|
||||
|
||||
Renders as:
|
||||
|
||||

|
||||
|
||||
</TabItem>
|
||||
<TabItem value="using-latex-in-code-blocks" label="Using LaTeX in Code Blocks">
|
||||
|
||||
Create formulas as code blocks by using LaTeX in a `latex` [code blocks](#code-blocks).
|
||||
|
||||
<Note>
|
||||
|
||||
This feature is [disabled by default](/administration-guide/configure/site-configuration-settings#enable-latex-code-block-rendering). Contact your system admin to enable this setting in **System Console \> Site Configuration \> Posts** to use this feature.
|
||||
|
||||
</Note>
|
||||
|
||||
```` text
|
||||
```latex
|
||||
X_k = \sum_{n=0}^{2N-1} x_n \cos \left[\frac{\pi}{N} \left(n+\frac{1}{2}+\frac{N}{2}\right) \left(k+\frac{1}{2}\right) \right]
|
||||
```
|
||||
````
|
||||
|
||||
Renders as:
|
||||
|
||||

|
||||
|
||||
</TabItem>
|
||||
</Tabs>
|
||||
|
||||
|
||||
<PlanAvailability slug="academy-message-formatting" />
|
||||
Reference in New Issue
Block a user