Skip to content

Commit 1a15592

Browse files
committed
docs(markdown): update Markdown documentation with new references
- Added reference to Markdown Syntax & Extensions in using-markdown.md - Clarified Markdown Editor Reference with additional details - Enhanced markdown-examples.md with links to relevant documentation
1 parent ecbc86e commit 1a15592

5 files changed

Lines changed: 60 additions & 15 deletions

File tree

docs/app/survey/explanation/understanding-css-variables.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,16 +20,16 @@ If you change the value of `--primary-color` in one place, every element using t
2020

2121
## How Accessible Surveys Uses CSS Variables
2222

23-
Accessible Surveys relies heavily on CSS variables to drive its styling and accessibility features.
23+
Accessible Surveys relies heavily on CSS variables to drive its styling and accessibility features.
2424

2525
### 1. Dynamic Theming
2626
When you configure the primary color or font of your survey in the styling editor, you aren't writing new CSS rules from scratch. Instead, you are updating the underlying CSS variables for the survey. The entire application layout references these variables, meaning your changes cascade instantly and consistently across buttons, headers, borders, and backgrounds.
2727

2828
### 2. Accessibility Modes (Dark, High Contrast)
29-
Our commitment to accessibility requires the interface to adapt to the user's needs on the fly.
30-
When a respondent switches to **Dark Mode** or **High Contrast Mode**, the platform simply swaps out the color palette assigned to the CSS variables.
29+
Our commitment to accessibility requires the interface to adapt to the user's needs on the fly.
30+
When a respondent switches to **Dark Mode** or **High Contrast Mode**, the platform simply swaps out the color palette assigned to the CSS variables.
3131

3232
Because the underlying CSS structure uses variables like `--text-color` and `--background-color` instead of hardcoded values (like `black` or `white`), the survey can instantly invert or heighten contrast without needing a completely separate stylesheet for every theme.
3333

3434
### 3. Responsive Overrides
35-
Variables also make it easy to adjust sizing based on the screen size (responsive design). We use variables to control padding and margins, which shrink automatically on mobile devices to ensure a comfortable reading experience.
35+
Variables also make it easy to adjust sizing based on the screen size (responsive design). We use variables to control padding and margins, which shrink automatically on mobile devices to ensure a comfortable reading experience.

docs/app/survey/explanation/using-markdown.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,7 @@ In a platform dedicated to accessibility and robust data collection, the structu
3939
---
4040

4141
**See also:**
42+
4243
* [How-to: Providing Rich Formatting](../how-to/providing-rich-formatting.md)
44+
* [Reference: Markdown Syntax & Extensions](../reference/content/markdown/index.md)
4345
* [Reference: Rich Text Editor Component](../../../components/md-editor.md)

docs/app/survey/how-to/styling-a-survey.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Learn how to customize the visual appearance of your survey, includ
44

55
# Styling a Survey
66

7-
Accessible Surveys provides a robust styling engine that allows you to customize the look and feel of your survey to match your brand while maintaining strict accessibility standards.
7+
Accessible Surveys provides a robust styling engine that allows you to customize the look and feel of your survey to match your brand while maintaining strict accessibility standards.
88

99
Because respondents can switch between high-contrast, dark, and light modes via the accessibility menu, the styling tools are designed to adapt automatically. This ensures your survey remains beautiful and legible regardless of the active accessibility mode.
1010

@@ -22,7 +22,7 @@ To access the styling options, you need to open the survey builder's **Behavior*
2222

2323
## Step 2: Configure Styling Options
2424

25-
The styling panel gives you access to various customization parameters.
25+
The styling panel gives you access to various customization parameters.
2626

2727
1. Expand the styling sections to access the configuration tools.
2828
2. Adjust the settings to match your desired aesthetic.
@@ -34,9 +34,10 @@ The styling panel gives you access to various customization parameters.
3434

3535
### Available Styling Controls
3636
While exact options may vary based on your plan, you typically have control over:
37-
* **Primary Colors**: Set the main brand color used for buttons, active states, and highlights.
38-
* **Typography**: Choose a base font family that is legible and web-safe.
39-
* **Layout Elements**: Control spacing, borders, and general alignment.
37+
38+
* **Primary Colors**: Set the main brand color used for buttons, active states, and highlights.
39+
* **Typography**: Choose a base font family that is legible and web-safe.
40+
* **Layout Elements**: Control spacing, borders, and general alignment.
4041

4142
::: tip
4243
**Accessibility First**
@@ -45,7 +46,7 @@ When you select a primary color, the platform automatically calculates appropria
4546

4647
## Step 3: Responsive Overrides (Optional)
4748

48-
You can also provide specific styling overrides based on how the respondent interacts with the survey.
49+
You can also provide specific styling overrides based on how the respondent interacts with the survey.
4950

5051
For example, you can adjust padding or layout styles specifically for **small screens** (mobile devices), or define how the layout behaves when the survey is set to display **one question per page**. These overrides ensure the user experience is optimized for every context.
5152

@@ -60,6 +61,6 @@ Always switch to the **Test** view to see how your styles look in a real environ
6061
## References
6162

6263
For more detailed technical information on how styling properties are managed and applied behind the scenes, please refer to:
63-
- [Reference: Behavior Settings](../reference/build/behavior.md)
64-
- [Reference: Customer Theme](../../customer/reference/customer/theme.md)
65-
- [Explanation: Understanding CSS Variables](../explanation/understanding-css-variables.md)
64+
* [Reference: Behavior Settings](../reference/build/behavior.md)
65+
* [Reference: Customer Theme](../../customer/reference/customer/theme.md)
66+
* [Explanation: Understanding CSS Variables](../explanation/understanding-css-variables.md)

docs/app/survey/reference/content/markdown/index.md

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,14 @@
22
description: Reference documentation for the Markdown editor and supported syntax extensions.
33
---
44

5-
# Markdown Editor
5+
# Markdown Editor Reference
66

77
The Markdown Free Text field in Accessible Surveys supports standard Markdown syntax along with custom HTML, CSS tokens, convenience classes, and embedded web components.
88

9+
::: info
10+
This reference focuses on the technical syntax and advanced styling available when writing Markdown and HTML manually. If you are looking for documentation on the visual editor toolbar, formatting shortcuts, and interactive widgets, please see the [Shared Components: Rich Text Editor](../../../../../components/md-editor.md) documentation.
11+
:::
12+
913
## Supported Syntax
1014

1115
* **Standard Markdown:** Basic formatting (bold `**text**`, italic `*text*`), headings (`#`, `##`), lists, and tables. See the [Markdown Guide](https://www.markdownguide.org/basic-syntax/).
@@ -51,3 +55,32 @@ The editor environment includes built-in classes and variables to integrate user
5155
}
5256
</style>
5357
```
58+
59+
### Understanding the Example
60+
61+
The code snippet above demonstrates how standard Markdown, raw HTML, convenience classes, accessibility modifiers, web components, and CSS tokens can all be combined into a single, cohesive block of text. Here is a breakdown of how it works:
62+
63+
#### 1. Layout and Spacing (Convenience Classes)
64+
The outer container uses `<div class="layout horizontal wrap gap">`.
65+
66+
* `layout horizontal` and `wrap` are built-in **Convenience Classes** that turn the container into a flexbox layout. Items will sit side-by-side (horizontally) and wrap to the next line if the screen is too small.
67+
* The child elements use the `flex` and `flex-2` classes. This means the third column (`flex-2`) will automatically take up twice as much horizontal space as the other columns (`flex`).
68+
69+
#### 2. Conditional Display (Accessibility Modes)
70+
The first two child `<div>` elements include the `show-when-signlanguage` and `show-when-easyread` classes.
71+
72+
* These are **Accessibility Mode** modifiers. The platform's rendering engine listens to the user's active settings. The first block of text will *only* be visible if the respondent has enabled Sign Language mode, while the second is exclusively for Easy Read mode.
73+
74+
#### 3. Mixing HTML and Markdown
75+
Notice that inside the HTML `<div>` tags, standard Markdown syntax like `**sign language mode**` is used freely to create bold text.
76+
77+
#### 4. Web Components
78+
Instead of pasting a messy iframe from YouTube, the editor supports custom **Web Components**.
79+
80+
* The `<lite-youtube videoid="xVytWVHX4N0"></lite-youtube>` tag creates a highly optimized, accessible video player simply by providing the video ID.
81+
82+
#### 5. Theming (CSS Tokens)
83+
Finally, a `<style>` block is included to define the custom `.box` and `.gap` classes.
84+
85+
* Instead of hardcoding colors (e.g., `background-color: blue`), it uses **CSS Tokens** like `var(--color-primary)` and `var(--color-on-primary)`.
86+
* If the survey is viewed in Dark Mode, or if the Customer Theme defines a different primary brand color, these variables update automatically. This ensures the custom styling remains accessible and visually consistent without requiring manual media queries.

docs/markdown-examples.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,15 @@
11
# Markdown Extension Examples
22

3-
This page demonstrates some of the built-in markdown extensions provided by VitePress.
3+
This page demonstrates some of the built-in markdown extensions provided by the VitePress documentation engine itself (this is used for writing *these* docs, rather than the Markdown used in the actual Survey App).
4+
5+
::: info
6+
If you are looking for documentation on how Markdown is used within the Accessible Surveys application, please see:
7+
8+
* [Explanation: Using Markdown](./app/survey/explanation/using-markdown.md)
9+
* [How-to: Providing Rich Formatting](./app/survey/how-to/providing-rich-formatting.md)
10+
* [Reference: Markdown Syntax & Extensions](./app/survey/reference/content/markdown/index.md)
11+
* [Shared Component: Rich Text Editor](./components/md-editor.md)
12+
:::
413

514
## Syntax Highlighting
615

0 commit comments

Comments
 (0)