diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
new file mode 100644
index 00000000000..b1f04ad75d3
--- /dev/null
+++ b/.github/CODEOWNERS
@@ -0,0 +1,14 @@
+# Lines starting with '#' are comments.
+# Each line is a file pattern followed by one or more owners.
+
+# More details are here: https://help.github.com/articles/about-codeowners/
+
+# The '*' pattern is global owners.
+
+# Order is important. The last matching pattern has the most precedence.
+# The folders are ordered as follows:
+
+# In each subsection folders are ordered first by depth, then alphabetically.
+# This should make it easy to add new rules without breaking existing ones.
+
+* @ionic-team/framework
diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md
deleted file mode 100644
index 1a0efc743b7..00000000000
--- a/.github/ISSUE_TEMPLATE/bug_report.md
+++ /dev/null
@@ -1,32 +0,0 @@
----
-name: Bug report
-about: Report a bug on the docs site
-title: ''
-labels: bug
-assignees: ''
-
----
-
-**Describe the bug**
-A clear and concise description of what the bug is.
-
-**To reproduce**
-Steps to reproduce the behavior:
-1. Go to '...'
-2. Click on '....'
-3. Scroll down to '....'
-4. See error
-
-**Expected behavior**
-A clear and concise description of what you expected to happen.
-
-**Screenshots**
-If applicable, add screenshots to help explain your problem.
-
-**Browser and OS (please complete the following information)**
- - OS: [e.g. iOS]
- - Browser: [e.g. chrome, safari]
- - Version: [e.g. 22]
-
-**Additional context**
-Add any other context about the problem here.
diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml
new file mode 100644
index 00000000000..3cae620736e
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/bug_report.yml
@@ -0,0 +1,43 @@
+name: 🐛 Bug Report
+description: Report a bug on the docs site
+labels: ["triage"]
+title: "bug: "
+body:
+ - type: textarea
+ attributes:
+ label: Describe the Bug
+ description: A clear description of what the bug is and how it manifests.
+ validations:
+ required: true
+ - type: textarea
+ attributes:
+ label: Expected Behavior
+ description: A clear description of what you expected to happen.
+ validations:
+ required: true
+ - type: textarea
+ attributes:
+ label: Steps to Reproduce
+ description: Please explain the steps required to duplicate this issue.
+ validations:
+ required: true
+ - type: textarea
+ attributes:
+ label: Screenshots
+ description: If applicable, add screenshots to help explain the problem.
+ - type: input
+ attributes:
+ label: Operating System
+ description: The operating system you are running (e.g. Windows)
+ - type: input
+ attributes:
+ label: Browser
+ description: The browser you are running (e.g. Chrome, Safari)
+ - type: input
+ attributes:
+ label: Version
+ description: The browser version you are running (e.g. 14)
+ - type: textarea
+ attributes:
+ label: Additional Information
+ description: List any other information that is relevant to your issue.
diff --git a/.github/ISSUE_TEMPLATE/content-issue.md b/.github/ISSUE_TEMPLATE/content-issue.md
deleted file mode 100644
index 58b864b751c..00000000000
--- a/.github/ISSUE_TEMPLATE/content-issue.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-name: Content issue
-about: Report missing or inaccurate content on the docs
-title: ''
-labels: content
-assignees: ''
-
----
-
-**URL**
-The URL at which the content is missing or inaccurate
-
-**What is missing or inaccurate about the content on this page?**
diff --git a/.github/ISSUE_TEMPLATE/content-issue.yml b/.github/ISSUE_TEMPLATE/content-issue.yml
new file mode 100644
index 00000000000..404492e1736
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/content-issue.yml
@@ -0,0 +1,17 @@
+name: 📕 Content Issue
+description: Report missing or inaccurate content on the docs
+labels: ["triage"]
+title: "content: "
+body:
+ - type: input
+ attributes:
+ label: URL
+ description: The URL at which the content is missing or inaccurate
+ validations:
+ required: true
+ - type: textarea
+ attributes:
+ label: Issue Description
+ description: What is missing or inaccurate about the content on this page?
+ validations:
+ required: true
diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md
deleted file mode 100644
index d513e5c0428..00000000000
--- a/.github/ISSUE_TEMPLATE/feature_request.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-name: Feature request
-about: Suggest a feature for the docs
-title: ''
-labels: feature
-assignees: ''
-
----
-
-**Is your feature request related to a problem? Please describe.**
-A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
-
-**Describe the solution you'd like**
-A clear and concise description of what you want to happen.
-
-**Describe alternatives you've considered**
-A clear and concise description of any alternative solutions or features you've considered.
-
-**Additional context**
-Add any other context or screenshots about the feature request here.
diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml
new file mode 100644
index 00000000000..5a964579982
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/feature_request.yml
@@ -0,0 +1,23 @@
+name: 💡 Feature Request
+description: Suggest a feature for the docs
+labels: ["triage"]
+title: "feat: "
+body:
+ - type: textarea
+ attributes:
+ label: Describe Problem
+ description: A clear and concise description of what the problem is. Ex. I am always frustrated when [...]
+ validations:
+ required: true
+ - type: textarea
+ attributes:
+ label: Describe Preferred Solution
+ description: A clear and concise description of what you want to happen.
+ - type: textarea
+ attributes:
+ label: Describe Alternatives
+ description: A clear and concise description of any alternative solutions or features you have considered.
+ - type: textarea
+ attributes:
+ label: Additional Information
+ description: Add any other context or screenshots about the feature request here.
\ No newline at end of file
diff --git a/.github/ionic-issue-bot.yml b/.github/ionic-issue-bot.yml
new file mode 100644
index 00000000000..f0da0d54073
--- /dev/null
+++ b/.github/ionic-issue-bot.yml
@@ -0,0 +1,86 @@
+triage:
+ label: triage
+ dryRun: false
+
+closeAndLock:
+ labels:
+ - label: 'ionitron: support'
+ message: >
+ Thanks for the issue! This issue appears to be a support request. We use this issue tracker exclusively for
+ content issues, bug reports and feature requests related to the documentation. Please use our
+ [forum](https://forum.ionicframework.com/) for help or questions about Ionic Framework.
+
+
+ Thank you for using Ionic!
+ - label: 'ionitron: missing template'
+ message: >
+ Thanks for the issue! It appears that you have not filled out the provided issue template. We use this issue
+ template in order to gather more information and further assist you. Please create a new issue and ensure the
+ template is fully filled out.
+
+
+ Thank you for using Ionic!
+ close: true
+ lock: true
+ dryRun: false
+
+comment:
+ labels:
+ - label: "help wanted"
+ message: >
+ This issue has been labeled as `help wanted`. This label is added to issues
+ that we believe would be good for contributors.
+
+
+ If you'd like to work on this issue, please comment here letting us know that
+ you would like to submit a pull request for it. This helps us to keep track of
+ the pull request and make sure there isn't duplicated effort.
+
+
+ For a guide on how to create a pull request and test this project locally to see
+ your changes, see our [contributing documentation](https://github.com/ionic-team/ionic-docs/blob/main/CONTRIBUTING.md).
+
+
+ Thank you!
+ - label: 'ionitron: needs reproduction'
+ message: >
+ Thanks for the issue! This issue has been labeled as `needs reproduction`. This label is added to issues that
+ we are not able to reproduce.
+
+
+ Please provide easy to follow steps for us to reproduce this issue.
+ dryRun: false
+
+noReply:
+ days: 14
+ maxIssuesPerRun: 100
+ label: "needs: reply"
+ responseLabel: triage
+ exemptProjects: true
+ exemptMilestones: true
+ message: >
+ Thanks for the issue! This issue is being closed due to the lack of a reply. If this is still an issue,
+ please create a new issue and ensure the template is fully filled out.
+
+
+ Thank you for using Ionic!
+ close: true
+ lock: true
+ dryRun: false
+
+noReproduction:
+ days: 14
+ maxIssuesPerRun: 100
+ label: "ionitron: needs reproduction"
+ responseLabel: triage
+ exemptProjects: true
+ exemptMilestones: true
+ message: >
+ Thanks for the issue! This issue is being closed due to the lack of a reproduction. If this is still an issue,
+ please create a new issue and ensure the template is fully filled out.
+
+
+ Thank you for using Ionic!
+ close: true
+ lock: true
+ dryRun: false
diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml
new file mode 100644
index 00000000000..750cea4b16e
--- /dev/null
+++ b/.github/workflows/CI.yml
@@ -0,0 +1,34 @@
+# GitHub Actions docs
+# https://help.github.com/en/articles/about-github-actions
+# https://help.github.com/en/articles/workflow-syntax-for-github-actions
+
+name: Install Dependencies, Lint
+
+on: [pull_request]
+
+jobs:
+ test:
+ name: Test on ${{ matrix.os }}
+ runs-on: ${{ matrix.os }}
+ strategy:
+ matrix:
+ node_version: [20]
+ os: [windows-latest, macOS-latest]
+
+ steps:
+ - uses: actions/checkout@v4
+ - name: Use Node.js ${{ matrix.node_version }}
+ uses: actions/setup-node@v4
+ with:
+ node-version: ${{ matrix.node_version }}
+ - name: Install Dependencies
+ run: npm ci --legacy-peer-deps
+ - name: Lint
+ run: npm run lint
+ - name: Spell Check
+ run: npm run spellcheck
+ # Lint and spell check changes should be pushed
+ # to the branch before the branch is merge eligible.
+ - name: Check Diff
+ run: git diff --exit-code
+ shell: bash
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
new file mode 100644
index 00000000000..fef3fa51da8
--- /dev/null
+++ b/.github/workflows/deploy.yml
@@ -0,0 +1,43 @@
+name: Deploy
+on:
+ push:
+ branches: [ main ]
+jobs:
+ build:
+
+ runs-on: ubuntu-latest
+
+ steps:
+ - uses: actions/checkout@v3
+ - uses: actions/setup-node@v3
+ with:
+ node-version: 20.x
+ cache: 'npm'
+ cache-dependency-path: package-lock.json
+
+ - name: prepare code
+ run: git clone https://github.com/ionic-jp/community-site.git site
+
+ # community-siteのビルド
+ - name: community-site build
+ run: |
+ npm install
+ npm run build.ci
+ working-directory: site
+
+ # Docsのビルド
+ - name: npm install, build
+ run: |
+ npm ci --legacy-peer-deps
+ npm run prebuild
+ npm run build:ci
+ mv site/www/* www/
+
+ # デプロイ
+ - name: deploy
+ run: |
+ npx netlify-cli deploy \
+ --site ${{ secrets.NETLIFY_SITE_ID }} \
+ --dir www/ \
+ --auth ${{ secrets.NETLIFY_TOKEN }} \
+ --prod
diff --git a/.gitignore b/.gitignore
index 31aea381f0b..e34ae50b1dc 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,6 +3,8 @@
# Production
/build
+/www
+/i18n
# Generated files
.docusaurus
@@ -19,4 +21,6 @@ src/components/page/reference/ReleaseNotes/release-notes.json
npm-debug.log*
yarn-debug.log*
-yarn-error.log*
\ No newline at end of file
+yarn-error.log*
+
+static/**/node_modules/
diff --git a/.npmrc b/.npmrc
new file mode 100644
index 00000000000..860dc500f0d
--- /dev/null
+++ b/.npmrc
@@ -0,0 +1 @@
+node-options=--max_old_space_size=4096
diff --git a/.prettierignore b/.prettierignore
index 85fee6b4234..c750d314e8a 100644
--- a/.prettierignore
+++ b/.prettierignore
@@ -1,13 +1,18 @@
src/theme/DocItem
-src/theme/DocPage
+src/theme/DocRoot
legacy-stencil-components
-node_modules
scripts/bak
-src/styles.bak
-src/pages
+
docs/api
docs/native
+versioned_docs/version-v*/native
docs/cli/commands
+docs/reference/glossary.md
+
+static/code/stackblitz
.docusaurus
-.github
\ No newline at end of file
+.github
+build
+node_modules
+src/translate
diff --git a/.prettierrc.js b/.prettierrc.js
deleted file mode 100644
index 4122fc68e28..00000000000
--- a/.prettierrc.js
+++ /dev/null
@@ -1,11 +0,0 @@
-module.exports = {
- ...require("@ionic/prettier-config"),
- overrides: [
- {
- files: "*.md",
- options: {
- "parser": "mdx"
- }
- }
- ]
-};
\ No newline at end of file
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 7184cf5f7d7..6452724858e 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -4,6 +4,9 @@ Thanks for your interest in contributing to Ionic's documentation! :tada: Check
- [Contributing Guide](#contributing-guide)
- [Development Workflow](#development-workflow)
+ - [Previewing Changes](#previewing-changes)
+ - [Linting Documentation](#linting-documentation)
+ - [Spell Check](#spell-check)
- [Using VS Code on Windows](#using-vs-code-on-windows)
- [Project Structure](#project-structure)
- [Directories](#directories)
@@ -12,7 +15,6 @@ Thanks for your interest in contributing to Ionic's documentation! :tada: Check
- [Translation](#translation)
- [Reporting Issues](#reporting-issues)
- [Pull Request Guidelines](#pull-request-guidelines)
-
- [Deploying](#deploying)
- [License](#license)
@@ -20,14 +22,67 @@ Thanks for your interest in contributing to Ionic's documentation! :tada: Check
## Development Workflow
+### Previewing Changes
+
In order to run the documentation locally, install the dependencies and run the development server:
```sh
-$ npm install
-$ npm start
+npm install
+npm start
+```
+
+### Linting Documentation
+
+This repository uses [Prettier](https://prettier.io/), an opinionated code formatter, in order to keep consistent formatting throughout the documentation. Run the following command to automatically fix all formatting, and then push any changes:
+
+```
+npm run lint
+```
+
+### Spell Check
+
+This repository uses [cspell](https://cspell.org/), a spell checker for code, to automatically flag any spelling errors. Run the following command to see any spelling errors:
+
+```
+npm run spellcheck
```
-> **Note**: recent versions of npm (5+) and Node.js (10+) are required to run certain scripts.
+> [!NOTE]
+> Any spelling errors will need to be fixed manually. There are various ways to ignore words or sections that were flagged erroneously. These are listed below.
+
+#### Ignoring words
+
+**To ignore:**
+
+- A **specific word**, add it to the following file: `cspell-wordlist.txt`
+ - For example, `Ionicons` is flagged as an unknown word. Since this is the name of our software, it has been added to this file to be ignored.
+- A **directory** or anything matching a **regular expression**, update the following file: `cspell.json`
+ - For example, we don't want to flag anything inside of code ticks (`
) or code blocks (```
), so there are regular expressions added to ignore anything inside of these.
+- An **entire line**, add the following comment above it:
+ ```markdown
+
+ ```
+- **Multiple lines**, add comments above and below the lines to be ignored:
+
+ ```markdown
+
+
+
Everything inside of these comments will be ignored by the spell checkr. Proofread your own words carefully.
+ + + ``` + +> [!IMPORTANT] +> You need to have line breaks between the `cspell` comments and any HTML elements, +> otherwise the build will error with `Module build failed`. + +#### Tips + +Before adding a word or section to be ignored, see if there is a way to make it pass the spell check. Technical terms that are part of an API may need to be wrapped in code formatting. For example, the word `keydown` is flagged as an unknown word by the spell checker, but this is a [Web API event](https://developer.mozilla.org/en-US/docs/Web/API/Element/keydown_event). We can wrap any mentions of `keydown` in two backticks (\`keydown\`
) in order to avoid it being flagged by the spell checker.
+
+Comments disabling the next line or entire sections of documentation are useful for making the spell checker ignore people's names.
+
+In general, we should try to avoid ignoring words unless they are technical terms that are used throughout the documentation and wouldn't necessarily make sense formatted as code.
---
@@ -54,8 +109,9 @@ Ionic's documentation is built using [Docusaurus](https://docusaurus.io/). The c
- `components/` - styles split out into the components they target
- `static/`
- `demos/` - self-contained demos, optionally presented by pages via `demoUrl` YAML frontmatter
+ - `usage/` - playgrounds that can be created by running `npm run playground:new` [(docs)](_templates/README.md#new-playground-template)
- `versioned_docs/` - versions of the docs created by the docusaurus versioning command
-- `versioned_sitebars/` - versions of the docs sidebars created by the docusaurus versioning command
+- `versioned_sidebars/` - versions of the docs sidebars created by the docusaurus versioning command
## Authoring Content
@@ -84,7 +140,9 @@ The Ionic docs have been translated into Japanese and are in the process of bein
We use Crowdin for our translation service. You can participate in the translation effort on the [Ionic Crowdin page](https://crowdin.com/project/ionic-docs).
-_Please submit translation issues to the Crowdin page and not the Ionic Docs GitHub repo_
+_Please submit translation issues to the Crowdin page and not the Ionic Docs GitHub repo._
+
+
The Japanese translation of the docs were built by an independent team, lead by [rdlabo](https://github.com/rdlabo) and can be found and contributed to on the [ionic-jp group's `ionic-docs` project page](https://github.com/ionic-jp/ionic-docs).
@@ -99,7 +157,8 @@ If the issue you're reporting is a bug, please be sure it is an issue with the I
- OS and browser versions
- If possible, a demo repo or CodePen/CodeSandbox
-> **Note**: Some [reference content](#reference-content) is pulled from other Ionic repos. In that case, please submit your issue on the docs repo with a link to the repo where the content lives.
+> [!NOTE]
+> Some [reference content](#reference-content) is pulled from other Ionic repos. In that case, please submit your issue on the docs repo with a link to the repo where the content lives.
---
@@ -109,20 +168,6 @@ When submitting pull requests, please keep the scope of your change contained to
---
-
-
## Deploying
The Ionic documentation's `main` branch is deployed automatically and separately from the [Ionic site](https://github.com/ionic-team/ionic-site) itself. The Ionic site then uses a proxy for paths under `/docs` to request the deployed documentation.
@@ -133,4 +178,4 @@ The Ionic documentation's `main` branch is deployed automatically and separately
This repo is licensed and managed separately from Ionic itself.
-By contributing to this repo, you agree to have your contributions licensed under the Apache 2.0 license. See [LICENSE](../LICENSE) for the full license text.
+By contributing to this repo, you agree to have your contributions licensed under the Apache 2.0 license. See [LICENSE](LICENSE) for the full license text.
diff --git a/_templates/README.md b/_templates/README.md
new file mode 100644
index 00000000000..60a3ebef83d
--- /dev/null
+++ b/_templates/README.md
@@ -0,0 +1,32 @@
+# Hygen templates
+
+The templates in this directory are intended to be used with [hygen](https://www.hygen.io/) to generate boilerplate files. Check out [the root package.json](../package.json) to see if there are any custom commands to use them (e.g. `npm run playground:new`). You can also run e.g. `hygen playground new` to use a generator.
+
+Some helpful docs links for updating/creating templates:
+
+- [enquirer](https://github.com/enquirer/enquirer#toggle-prompt) for building command line prompts
+- [inflection](https://www.hygen.io/docs/templates#helpers-and-inflections) and [change case](https://www.hygen.io/docs/templates#change-case-helpers) for e.g. changing the case of variables submitted via the prompts
+
+# New playground template
+
+## Generation
+
+To create a new playground, run `npm run playground:new`. This will walk you through some prompts to decide what files for the generator to create for the playground, and what their paths should be.
+
+The path defaults to `basic`. If there is already a basic playground, you'll want to input a different path for the playground.
+
+The CSS option will add extra files if you need to include custom CSS in your playground.
+
+If you need a component for multiple versions of Ionic Framework, you (currently) need to run the generator once for each version.
+
+## Usage
+
+Once you've generated your playground, you need to add it to the main markdown file in the docs (e.g. [docs/api/button.md](../docs/api/button.md)) by doing something similar to the following example:
+
+```
+## Feature
+
+import Feature from '@site/static/usage/v8/button/feature/index.md';
+
+Learn the fundamentals you need to know to start building amazing apps with Ionic Framework.
+Learn the basics of navigation inside your app with Ionic and Angular Router
+Learn about using Ionic lifecycle events in class components and with hooks
+Learn about using Modules or Standalone Components in Ionic.
+aria-hidden="true"
を持つべきです。これは、アイコンを視覚的に隠すことはできませんが、支援技術からその要素を隠すことができます。
+
+```html
+
+```
+
+
+アイコンがインタラクティブな場合は、aria-label
を追加することで代替テキストを定義する必要があります。
+
+```html
+aria-label
を付加し、 aria-hidden
でアイコンを非表示とします。
+
+```html
+A new message in your network
-Oceanic Next has joined your network
-A new message in your network
-Oceanic Next has joined your network
-A new message in your network
-Oceanic Next has joined your network
-A new message in your network
-Oceanic Next has joined your network
-A new message in your network
-Oceanic Next has joined your network
-Paragraph line 1
-Paragraph line 2 secondary
-Button on right
-Icon on right
-Button on right
-Icon on right
-Paragraph line 1
-Paragraph line 2 secondary
-Button on right
-Icon on right
-Paragraph line 1
-Paragraph line 2 secondary
-Button on right
-Icon on right
-Paragraph line 1
-Paragraph line 2 secondary
-Button on right
-Icon on right
-picked: {{ picked.animal.text }}
-Default Searchbar
-Searchbar with cancel button always shown
-Searchbar with cancel button never shown
-Searchbar with cancel button shown on focus
-Searchbar with danger color
-Searchbar with telephone type
-Searchbar with numeric inputmode
-Searchbar disabled
-Searchbar with a cancel button and custom cancel button text
-Searchbar with a custom debounce - Note: debounce only works on onIonChange event
-Animated Searchbar
-Searchbar with a placeholder
-Searchbar in a Toolbar
-