From 67a294a93d21987508fd2847e86782d1a63125a4 Mon Sep 17 00:00:00 2001
From: Charly Abraham
Date: Tue, 10 Nov 2026 12:44:04 +0530
Subject: [PATCH 1/3] docs: add guided tutorials and release validation
Add Community and Pro walkthroughs with practice projects, screenshots, captioned videos, FAQs, and product icons. Expand project startup, find-and-replace, and extension troubleshooting guidance.
Generate llms.txt and video metadata through Docusaurus, preserve first-publication dates across deployments, and validate tutorial files and links before release.
Validated preview and release builds, seven release tests, tutorial asset checks, and browser behavior.
---
.github/workflows/build-verify.yml | 6 +
.github/workflows/gh-pages-deploy.yml | 18 +-
.gitignore | 1 +
README.md | 46 +++-
.../02-quick-start-project.md | 23 ++
docs/01-Getting Started/index.md | 1 +
docs/02-Live Preview/02-live-preview-edit.md | 4 +-
docs/02-Live Preview/07-image-gallery.md | 4 +-
docs/02-Live Preview/index.md | 2 +-
docs/05-Workspace/01-file-management.md | 2 +
docs/05-Workspace/02-find-in-files.md | 98 ++++++-
docs/07-Code Intelligence/04-python.md | 2 +
docs/08-Extensions & Themes/01-extensions.md | 42 +++
docs/10-Tutorials/01-add-images.md | 256 ++++++++++++++++++
docs/10-Tutorials/02-link-pages.md | 141 ++++++++++
docs/10-Tutorials/03-share-website.md | 145 ++++++++++
docs/10-Tutorials/04-bootstrap.md | 128 +++++++++
docs/10-Tutorials/05-run-python.md | 147 ++++++++++
docs/10-Tutorials/_category_.json | 6 +
docs/10-Tutorials/index.md | 32 +++
docs/images/tutorials/practice-website.png | Bin 0 -> 69738 bytes
docusaurus.config.js | 5 +
package.json | 3 +
plugins/llms-txt/index.js | 107 ++++++++
plugins/tutorial-media/index.js | 45 +++
plugins/tutorial-media/publications.js | 24 ++
scripts/package-tutorials.py | 32 +++
scripts/prepare-tutorial-publications.cjs | 48 ++++
scripts/tutorial-media-manifest.json | 82 ++++++
scripts/tutorial-release.test.cjs | 121 +++++++++
scripts/verify-tutorials.py | 186 +++++++++++++
.../TutorialIcon/LICENSE-FONT-AWESOME.txt | 165 +++++++++++
src/components/TutorialIcon/icons.js | 21 ++
src/components/TutorialIcon/index.js | 21 ++
src/components/TutorialIcon/sources.json | 26 ++
src/components/TutorialIcon/styles.module.css | 20 ++
src/components/Video/TutorialVideo.js | 116 ++++++++
static/robots.txt | 17 +-
static/tutorials/bootstrap-starter.zip | Bin 0 -> 943 bytes
static/tutorials/bootstrap-starter/index.html | 30 ++
static/tutorials/first-website.zip | Bin 0 -> 3113 bytes
static/tutorials/first-website/about.html | 32 +++
static/tutorials/first-website/contact.html | 27 ++
.../tutorials/first-website/images/trail.svg | 8 +
static/tutorials/first-website/index.html | 28 ++
static/tutorials/first-website/styles.css | 80 ++++++
.../media/bootstrap-community-result.png | Bin 0 -> 189880 bytes
.../tutorials/media/bootstrap-pro-classes.png | Bin 0 -> 14451 bytes
.../media/bootstrap-pro-design-mode.png | Bin 0 -> 65050 bytes
.../tutorials/media/community-add-image.mp4 | Bin 0 -> 842979 bytes
.../tutorials/media/community-add-image.vtt | 16 ++
.../media/community-highlight-menu.png | Bin 0 -> 20545 bytes
.../media/community-image-result.png | Bin 0 -> 461152 bytes
.../media/community-insert-image.png | Bin 0 -> 472123 bytes
.../media/community-link-location.png | Bin 0 -> 204356 bytes
.../media/community-select-image-tag.png | Bin 0 -> 200993 bytes
.../media/first-website-design-mode.png | Bin 0 -> 92734 bytes
.../media/pro-add-image-complete.mp4 | Bin 0 -> 1124941 bytes
.../media/pro-add-image-complete.vtt | 34 +++
.../media/pro-image-description-complete.png | Bin 0 -> 7584 bytes
.../media/pro-image-design-result.png | Bin 0 -> 856546 bytes
static/tutorials/media/pro-image-gallery.png | Bin 0 -> 328890 bytes
.../tutorials/media/pro-link-design-mode.png | Bin 0 -> 102707 bytes
.../tutorials/media/pro-save-image-folder.png | Bin 0 -> 24608 bytes
.../media/pro-select-from-device.png | Bin 0 -> 138058 bytes
static/tutorials/photo.jpg | Bin 0 -> 279866 bytes
66 files changed, 2370 insertions(+), 28 deletions(-)
create mode 100644 docs/10-Tutorials/01-add-images.md
create mode 100644 docs/10-Tutorials/02-link-pages.md
create mode 100644 docs/10-Tutorials/03-share-website.md
create mode 100644 docs/10-Tutorials/04-bootstrap.md
create mode 100644 docs/10-Tutorials/05-run-python.md
create mode 100644 docs/10-Tutorials/_category_.json
create mode 100644 docs/10-Tutorials/index.md
create mode 100644 docs/images/tutorials/practice-website.png
create mode 100644 plugins/llms-txt/index.js
create mode 100644 plugins/tutorial-media/index.js
create mode 100644 plugins/tutorial-media/publications.js
create mode 100644 scripts/package-tutorials.py
create mode 100644 scripts/prepare-tutorial-publications.cjs
create mode 100644 scripts/tutorial-media-manifest.json
create mode 100644 scripts/tutorial-release.test.cjs
create mode 100644 scripts/verify-tutorials.py
create mode 100644 src/components/TutorialIcon/LICENSE-FONT-AWESOME.txt
create mode 100644 src/components/TutorialIcon/icons.js
create mode 100644 src/components/TutorialIcon/index.js
create mode 100644 src/components/TutorialIcon/sources.json
create mode 100644 src/components/TutorialIcon/styles.module.css
create mode 100644 src/components/Video/TutorialVideo.js
create mode 100644 static/tutorials/bootstrap-starter.zip
create mode 100644 static/tutorials/bootstrap-starter/index.html
create mode 100644 static/tutorials/first-website.zip
create mode 100644 static/tutorials/first-website/about.html
create mode 100644 static/tutorials/first-website/contact.html
create mode 100644 static/tutorials/first-website/images/trail.svg
create mode 100644 static/tutorials/first-website/index.html
create mode 100644 static/tutorials/first-website/styles.css
create mode 100644 static/tutorials/media/bootstrap-community-result.png
create mode 100644 static/tutorials/media/bootstrap-pro-classes.png
create mode 100644 static/tutorials/media/bootstrap-pro-design-mode.png
create mode 100644 static/tutorials/media/community-add-image.mp4
create mode 100644 static/tutorials/media/community-add-image.vtt
create mode 100644 static/tutorials/media/community-highlight-menu.png
create mode 100644 static/tutorials/media/community-image-result.png
create mode 100644 static/tutorials/media/community-insert-image.png
create mode 100644 static/tutorials/media/community-link-location.png
create mode 100644 static/tutorials/media/community-select-image-tag.png
create mode 100644 static/tutorials/media/first-website-design-mode.png
create mode 100644 static/tutorials/media/pro-add-image-complete.mp4
create mode 100644 static/tutorials/media/pro-add-image-complete.vtt
create mode 100644 static/tutorials/media/pro-image-description-complete.png
create mode 100644 static/tutorials/media/pro-image-design-result.png
create mode 100644 static/tutorials/media/pro-image-gallery.png
create mode 100644 static/tutorials/media/pro-link-design-mode.png
create mode 100644 static/tutorials/media/pro-save-image-folder.png
create mode 100644 static/tutorials/media/pro-select-from-device.png
create mode 100644 static/tutorials/photo.jpg
diff --git a/.github/workflows/build-verify.yml b/.github/workflows/build-verify.yml
index 64d7e91b4..c30d26ba7 100644
--- a/.github/workflows/build-verify.yml
+++ b/.github/workflows/build-verify.yml
@@ -21,5 +21,11 @@ jobs:
- name: Install dependencies
run: npm ci
+ - name: Test tutorial release tooling
+ run: npm run test:tutorials
+ - name: Package tutorial projects
+ run: npm run package:tutorials
- name: Build website
run: npm run build
+ - name: Verify tutorial release files
+ run: npm run verify:tutorials
diff --git a/.github/workflows/gh-pages-deploy.yml b/.github/workflows/gh-pages-deploy.yml
index c8c282eab..beae8c855 100644
--- a/.github/workflows/gh-pages-deploy.yml
+++ b/.github/workflows/gh-pages-deploy.yml
@@ -10,10 +10,16 @@ on:
permissions:
contents: write
+concurrency:
+ group: docs-production
+ cancel-in-progress: false
+
jobs:
deploy:
name: Deploy to GitHub Pages
runs-on: ubuntu-latest
+ env:
+ PHCODE_VIDEO_PUBLICATIONS_FILE: .tutorial-video-publications.json
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
@@ -23,8 +29,18 @@ jobs:
- name: Install dependencies
run: npm ci
+ - name: Test tutorial release tooling
+ run: npm run test:tutorials
+ - name: Package tutorial projects
+ run: npm run package:tutorials
+ - name: Restore original video publication dates
+ run: node scripts/prepare-tutorial-publications.cjs
- name: Build website
run: npm run build
+ env:
+ PHCODE_PUBLISH_TUTORIAL_VIDEOS: '1'
+ - name: Verify tutorial release files and metadata
+ run: npm run verify:tutorials -- --release
- name: copy cname to build folder
run: cp CNAME ./build
@@ -42,4 +58,4 @@ jobs:
# The GH actions bot is used by default if you didn't specify the two fields.
# You can swap them out with your own user credentials.
user_name: github-actions[bot]
- user_email: 41898282+github-actions[bot]@users.noreply.github.com
\ No newline at end of file
+ user_email: 41898282+github-actions[bot]@users.noreply.github.com
diff --git a/.gitignore b/.gitignore
index 87096ce01..1d85f52c1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -13,6 +13,7 @@ resources
# Generated files
.docusaurus
.cache-loader
+/.tutorial-video-publications.json
api/API-Reference
phoenix
diff --git a/README.md b/README.md
index abcba775d..7454631f0 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@ CC BY License Copyright (c) 2022-present, core.ai
# Website
-This website is built using [Docusaurus 2](https://docusaurus.io/), a modern
+This website is built using [Docusaurus 3](https://docusaurus.io/), a modern
static website generator.
### Installation
@@ -36,19 +36,45 @@ $ npm run build
This command generates static content into the `build` directory and can be
served using any static contents hosting service.
-### Deployment
+### Tutorial release checks
-Using SSH:
+Run these checks before releasing tutorial changes. They require Node.js, Git,
+and Python 3. No extra Python packages are needed.
-```
-$ USE_SSH=true npm run deploy
+```sh
+npm run test:tutorials
+npm run package:tutorials
+npm run build
+npm run verify:tutorials
```
-Not using SSH:
+The checks cover tutorial links and anchors, image descriptions, video metadata
+and captions, AI documentation indexes, and the contents of both practice ZIPs.
+`npm run build` refreshes the API documentation from its source repository. If
+the API files are already generated locally, `npm run docusaurus -- build` builds
+the current checkout without refreshing them.
+To preview the built site, run:
+
+```sh
+npm run serve -- --port 8208
```
-$ GIT_USER= npm run deploy
-```
-If you are using GitHub pages for hosting, this command is a convenient way to
-build the website and push to the `gh-pages` branch.
+### Deployment
+
+The production workflow in `.github/workflows/gh-pages-deploy.yml` deploys reviewed
+changes pushed to `prod`. It runs the tutorial checks before publishing to
+`gh-pages`. Deployments run one at a time.
+
+Video first-publication dates are assigned automatically during a deployment
+build. The workflow restores `tutorials/video-publications.json` from the
+previous deployment, assigns dates to new videos, and includes the resulting
+manifest in the published site. Later releases preserve those original dates.
+Local preview builds leave unpublished dates unset; no manual edit to the guide
+is needed before release.
+
+Keep `tutorials/video-publications.json` when restoring or moving the published
+site. If an already published video has lost its recorded date, deployment stops
+until the original date is restored. An unavailable deployment history also
+stops the release. The final `verify:tutorials -- --release` check requires each
+video's page metadata to match its saved publication date.
diff --git a/docs/01-Getting Started/02-quick-start-project.md b/docs/01-Getting Started/02-quick-start-project.md
index 2883d0acc..1495d9efb 100644
--- a/docs/01-Getting Started/02-quick-start-project.md
+++ b/docs/01-Getting Started/02-quick-start-project.md
@@ -1,6 +1,7 @@
---
title: Quick Start Project
slug: "/quick-start-project"
+description: Create or open a Phoenix Code project, resume recent work, and reopen your website when the editor starts.
---
import React from 'react';
@@ -30,9 +31,29 @@ Additionally, if you prefer that the Start Project Dialog doesn't appear every t
+## Reopen your project on startup
+
+Phoenix Code remembers the last project folder you opened and tries to reopen it the next time you start the editor. To resume your own website:
+
+1. Choose **Open Folder** in the Start Project dialog and select the folder containing your website.
+2. Open `index.html` or the file you want to work on, then save your changes.
+3. If you prefer to go straight to your work, turn off **Show This Dialog on Startup** in the Start Project dialog's settings.
+4. Close Phoenix Code normally and open it again.
+
+The startup dialog setting controls the dialog's visibility. It does not choose a permanent favorite project: if you later open a different project, that becomes the project to resume.
+
+### Desktop and browser differences
+
+- **Desktop:** opening a particular file or folder from your operating system can take precedence over the previous project. The remembered folder also needs to remain available at the same location.
+- **Browser:** use the same browser profile and the same editor address. Local-folder access depends on browser permissions, so you may need to grant access again or use **Open Folder**. Projects stored in browser storage also depend on that browser's saved site data.
+
+If your previous folder is missing or cannot be restored, open it again from **Recent Projects** or **Open Folder**. Phoenix Code can also fall back to the welcome project after an unsuccessful startup.
+
## Default Project
The Start Project Dialog includes an option for creating a Default Project. When selected, a project will be generated with some files to provide a simple starting point for testing and using the Phoenix Code editor.
+**Default Project** is a starter project. To reopen your own website at launch, use [Reopen your project on startup](#reopen-your-project-on-startup).
+
@@ -63,6 +84,8 @@ You can create a new HTML project that includes essential files by following the
Once completed, a basic project structure will be generated in the selected folder.
+Continue with [Add images to an HTML page](/docs/tutorials/add-images) or [Connect pages with links](/docs/tutorials/link-pages). Both tutorials include an example project you can download.
+
diff --git a/docs/01-Getting Started/index.md b/docs/01-Getting Started/index.md
index a61f166f4..2b9af684c 100644
--- a/docs/01-Getting Started/index.md
+++ b/docs/01-Getting Started/index.md
@@ -59,6 +59,7 @@ Phoenix Code is for anyone building for the web, and especially:
- **Install it:** [Installation](/docs/intro)
- **Create your first project:** [Your First Project](/docs/quick-start-project)
+- **Build something step by step:** [Tutorials](/docs/tutorials) — images, linked pages, sharing, Bootstrap, and Python.
- **Our flagship feature:** [Live Preview](/docs/Features/Live%20Preview)
- **Try the AI assistant:** [AI](/docs/Pro%20Features/ai-chat)
diff --git a/docs/02-Live Preview/02-live-preview-edit.md b/docs/02-Live Preview/02-live-preview-edit.md
index 86c977643..2c9d2f59f 100644
--- a/docs/02-Live Preview/02-live-preview-edit.md
+++ b/docs/02-Live Preview/02-live-preview-edit.md
@@ -95,9 +95,9 @@ The right side of the Control Box displays a set of tools you can use to modify
*This button appears only for `` elements.*
See the [Edit Hyperlink](#edit-hyperlink) section for more details.
-- **Change Image** *(image icon)*: Opens an image gallery at the bottom of the Live Preview, where you can browse and select an image. You can also choose an image from your computer. Phoenix Code automatically saves the image to your project folder and updates the `src` attribute of the element.
+- **Image Gallery** *(image icon)*: Opens an image gallery at the bottom of the Live Preview. **Select from device** or the gallery's download icon saves a picture to your project and updates its `src`. Clicking an online thumbnail can use the provider's image URL instead.
*This button appears only for `` elements.*
- See [Image Gallery](./image-gallery) for more details.
+ See [Image Gallery](./image-gallery) for more details, or follow the [step-by-step image guide](/docs/tutorials/add-images).
- **Edit Text** *(pen icon)*: Opens inline text editing for the selected element. You can edit text directly in the Live Preview, and Phoenix Code automatically updates the source code.
*This button appears only for elements that can contain text (it is not available for ``, `
`. Click immediately after its `>`, then press **Enter** to make a new line.
+4. Paste this on the new line:
+
+```html
+
+```
+
+5. Use your second picture's filename and description, then save. The new picture appears below the paragraph.
+
+[](/tutorials/media/community-insert-image.png)
+
+For your own page, follow the same pattern: click a nearby paragraph, find its closing ``, and add the image after it, inside the page's ``.
+
+**Pro:** click an element near where you want the new picture. Click the in its floating toolbar, choose **Before** or **After**, then **Image**. Select the new picture and follow **Choose your picture** above. On an empty page, choose **Image** from the Starter Bar instead.
+
+You can use these same steps in your own website project.
+
+
+
+
+How do I make an image smaller?
+
+**Community:** in the practice project's `styles.css`, find the rule beginning `img {` and add `width: 480px;` on a new line inside its braces. Save. This sets the preferred width of every picture in this practice site; the existing `max-width` and `height` rules keep them responsive.
+
+**Pro:** select the picture in Edit Mode. In the [Styles Bar](/docs/Pro%20Features/styles-bar#box-model), open **Box Model > Size**. Set **Width** to `480px`, **Height** to `auto`, and **Min / max > Max width** to `100%`. Save.
+
+
+
+For online pictures and gallery downloads, see [Image Gallery](/docs/Pro%20Features/image-gallery).
+
+Sample photo: [Johannes Plenio on Unsplash](https://unsplash.com/photos/pathway-of-trees-during-daytime-P1Iz3unD6Po), used under the [Unsplash License](https://unsplash.com/license). Screenshots and recordings use Phoenix Code for the web; the Community steps use free features.
diff --git a/docs/10-Tutorials/02-link-pages.md b/docs/10-Tutorials/02-link-pages.md
new file mode 100644
index 000000000..5751f210b
--- /dev/null
+++ b/docs/10-Tutorials/02-link-pages.md
@@ -0,0 +1,141 @@
+---
+title: Link to another page
+slug: /tutorials/link-pages
+description: Make a Contact me link open another page of your website. Follow the Community or Phoenix Pro steps using a small practice project.
+toc_max_heading_level: 2
+---
+
+import Tabs from '@theme/Tabs';
+import TabItem from '@theme/TabItem';
+import TutorialIcon from '@site/src/components/TutorialIcon';
+
+Make a **Contact me** link on your home page that opens a separate Contact page. You'll also check that visitors can get back to Home.
+
+This guide works in Community (free) and Phoenix Pro.
+
+## 1. Open the practice website
+
+If you followed [Add an image to your website](/docs/tutorials/add-images), keep that project open.
+
+Otherwise, [download the practice website](/tutorials/first-website.zip), extract it, and use **Open Folder** in Phoenix Code to open the extracted `first-website` folder.
+
+Look in the file list on the left. You should see these three pages:
+
+- `index.html` — the home page.
+- `about.html` — the About page.
+- `contact.html` — the Contact page.
+
+## 2. Find the link you'll change
+
+1. Click `index.html` in the file list.
+2. Click the to open Live Preview.
+3. Scroll below the picture. Find **Read about this project →**.
+
+You'll turn that link into **Contact me** and make it open `contact.html`.
+
+## 3. Change the link
+
+Choose your edition. Both methods change the same link.
+
+
+
+
+1. Click the in the Live Preview toolbar to enter **Design Mode**. If the editor is already hidden, keep this view.
+2. If the in the preview toolbar is gray, click it to turn on **Edit Mode**. An means visual editing is on.
+3. Double-click **Read about this project →**.
+4. Replace the words with `Contact me` and press **Enter**.
+5. Click the link once to select it.
+6. Click the in its floating toolbar to open **Edit Hyperlink**.
+7. Enter `contact.html` in the URL field and press **Enter**.
+8. Click the in the narrow toolbar to the left of the preview. Its tooltip says **Save File**.
+
+Design Mode gives the preview more room; Edit Mode enables visual changes. Phoenix Code updates the HTML for you, and you can save without leaving Design Mode.
+
+[](/tutorials/media/pro-link-design-mode.png)
+
+
+
+
+1. Keep `index.html` open in the code editor. If the preview fills the app, click its to show the editor again.
+2. In the Live Preview toolbar, click the and choose **Highlight Mode**.
+3. Click the paragraph beginning **Every website starts with a first page**, just above the link. The editor moves to that paragraph's `
` tag.
+4. Look at the next line in the code: `Read about this project →`.
+5. Drag to select that entire `...` line, then paste:
+
+```html
+Contact me
+```
+
+6. Save with **Ctrl+S** or **Cmd+S**.
+
+`Contact me` is what the visitor sees. `contact.html` is the page that opens when they click it.
+
+We use the nearby paragraph to find the code because clicking the link in Highlight Mode can open its destination.
+
+[](/tutorials/media/community-link-location.png)
+
+Click the screenshot to view it full size. It uses the original practice page; your picture may look different if you followed the image guide first.
+
+
+
+
+**You should now see “Contact me” below the picture.**
+
+## 4. Test the link
+
+1. Click in the Live Preview toolbar.
+2. In the new browser window, click **Contact me**.
+3. Check that the Contact page opens. Its heading is **Keep in touch.**
+4. Click **Home** in the navigation at the top.
+
+You should return to the home page. Your link works in both directions because the Contact page already includes a Home link.
+
+Use the separate browser window to check how a visitor will use the page.
+
+## 5. Try one more change
+
+Change the link to open the About page instead. Use `about.html` as the destination and `About me` as the text. Save and test it again.
+
+When you're ready, [share your website](/docs/tutorials/share-website).
+
+## Need help?
+
+
+I can't find the link in the code
+
+Open `index.html`, press **Ctrl+F** on Windows/Linux or **Cmd+F** on macOS, and search for `Read about this project`. If you've already changed the words, search for `Contact me` instead.
+
+If the preview fills Phoenix Code, click the in its toolbar to show the editor again.
+
+
+
+
+The link says “file not found”
+
+Check that `contact.html` is saved beside `index.html` in the same folder. The link must use its exact filename, including `.html` and matching capital letters.
+
+If you put the Contact page in a folder named `pages`, use `pages/contact.html` instead. To return from that folder to the home page, use `../index.html`.
+
+
+
+
+How do I add a new link to my own page?
+
+**Community:** keep your HTML file open and use **Highlight Mode** to click a paragraph near where you want the link. In the editor, click after that paragraph's closing `` and press **Enter**. Paste `Contact me` on the new line, inside the page's ``, then save.
+
+**Pro:** select a nearby element in Edit Mode, click the , choose **Before** or **After**, then **Link**. Follow the text and destination steps above.
+
+Save the destination page first. A link points to another file; it doesn't create that file for you.
+
+
+
+
+How do I change the link color?
+
+**Community:** open `styles.css` and change the `color` value inside the `a { ... }` rule.
+
+**Pro:** select the link in Edit Mode and open the [Styles Bar](/docs/Pro%20Features/styles-bar#save-changes-to). Under **Save changes to**, choose the `a` rule in `styles.css`, then choose a text color.
+
+All three practice pages use that stylesheet, so their links will share the change. Choosing an inline style in Pro changes only the selected link.
+
+
diff --git a/docs/10-Tutorials/03-share-website.md b/docs/10-Tutorials/03-share-website.md
new file mode 100644
index 000000000..d586bf592
--- /dev/null
+++ b/docs/10-Tutorials/03-share-website.md
@@ -0,0 +1,145 @@
+---
+title: Share your website
+slug: /tutorials/share-website
+description: Send someone a link to your website or a ZIP of its files. Step-by-step instructions for Community and Phoenix Pro.
+toc_max_heading_level: 2
+---
+
+import Tabs from '@theme/Tabs';
+import TabItem from '@theme/TabItem';
+import TutorialIcon from '@site/src/components/TutorialIcon';
+
+Let someone else see the website you've made. You can send a link they open in a browser, or a ZIP they can keep and edit.
+
+These steps are the same in Community (free) and Phoenix Pro. They work for websites made from HTML, CSS, JavaScript, and images.
+
+## 1. Save and check your website
+
+1. Open your project in Phoenix Code.
+2. Choose **File > Save All**.
+3. Open `index.html` and show Live Preview with the .
+4. Check that the home page and its pictures appear.
+
+If you're using the practice website, you should see **Trail Notes** and the Home, About, and Contact links.
+
+## 2. Choose what to send
+
+Choose **Send a link** for a quick preview, **Send a ZIP** for editable files, or **Keep it online** for a permanent website address.
+
+
+
+
+### Publish a temporary preview
+
+This makes your website public for **three days**. Keep only files you want to share in this project.
+
+1. Select `index.html` in the file list.
+2. Find the (three connected dots) in Phoenix Code's right-hand toolbar. Hover over it: the tooltip says **Click to publish and share this site**.
+3. Click it to open **Publish and Share Website?**.
+4. Check the destination shown in the dialog, then choose **Publish**.
+5. Wait for the published page to open in your browser.
+6. Copy the address from that browser window and send it to the person who should view your site.
+
+**They should be able to open your website without opening Phoenix Code.** Send this new address, rather than the address of your editor or a local preview.
+
+To show a later change, save it in Phoenix Code. While the publishing session is active, the editor syncs the changes. Reload the published page to check them. If you have restarted the editor, follow the publishing steps again.
+
+
+
+
+### Package your website files
+
+A ZIP puts the whole website into one file. Send all the pages and pictures together so the website still works after extraction.
+
+**If you opened a folder from your computer:**
+
+1. Open that project folder's location in your computer's file manager.
+2. Right-click the folder. On Windows, choose **Compress to ZIP file**. On macOS, choose **Compress**.
+3. Send the resulting `.zip` file.
+
+For the practice website, compress the `first-website` folder. The archive should include `index.html`, the other pages, `styles.css`, and `images`.
+
+**If your project is stored inside the browser:**
+
+1. In Phoenix Code, choose **File > Download Project**.
+2. Save the `.zip` file when your browser asks.
+3. Send that file.
+
+If **Download Project** isn't in the menu, your project is already in a local folder. Use the file-manager steps above.
+
+**Tell the recipient to extract the ZIP first.** They can open `index.html` to view the website, or open the extracted folder in Phoenix Code to edit it.
+
+
+
+
+### Publish with GitHub Pages
+
+Use this when the website needs to stay online beyond a temporary preview. You'll need a GitHub account. This method makes the website and its source files public.
+
+1. Create a new **public repository** on GitHub for your website.
+2. Upload your website's files into it. Put `index.html` at the top level, next to your CSS file and image folder. Upload the extracted files, not the ZIP.
+3. Open the repository's **Settings**.
+4. Select **Pages**.
+5. Under **Build and deployment**, choose **Deploy from a branch**.
+6. Choose the branch containing your files, usually `main`, and the **/(root)** folder.
+7. Click **Save**.
+8. Wait for deployment to finish, then open the website address shown in Pages settings.
+
+**You should see your home page at its new public address.** Open About and Contact to check that those pages were uploaded too.
+
+GitHub's [publishing instructions](https://docs.github.com/en/pages/getting-started-with-github-pages/configuring-a-publishing-source-for-your-github-pages-site) show the current settings. You can also use [Git in Phoenix Code](/docs/Features/git) to push later changes.
+
+
+
+
+## 3. Check what the other person receives
+
+For a link, open it on another device. For a ZIP, extract it into a new folder and open its `index.html`.
+
+Check these three things:
+
+- The home page appears.
+- Every picture loads.
+- The page links open the right pages and let you get back to Home.
+
+**Your website is ready to share.**
+
+## Need help?
+
+
+I already have Hostinger or another web host
+
+Use your host's **File Manager** to upload the website files. On Hostinger web hosting, open the site's `public_html` folder and put `index.html` directly inside it, next to the other pages, CSS, and images.
+
+If you upload a ZIP, extract it there. Check that it hasn't left `index.html` inside an extra `first-website` folder. Keep a backup before replacing an existing website.
+
+See Hostinger's [File Manager instructions](https://www.hostinger.com/support/1869114-how-to-upload-backups-with-file-manager-in-hostinger/) for the upload steps. This method is for hosting that accepts your own files; a site managed by its AI Website Builder uses a different workflow.
+
+If your host gives you FTP or SFTP details, you can use a transfer client to upload the same files. After editing in Phoenix Code, upload the changed files again.
+
+
+
+
+The website opens, but its pictures or styles are missing
+
+Check that you sent the image folders and CSS files as well as the HTML pages. Keep the same folder arrangement as in your project. Match capital letters in filenames exactly.
+
+
+
+
+The other person can't open the link
+
+Copy the address of the published page. An address containing `localhost` only points to the device opening it. A Phoenix Code editor address opens the editor.
+
+The built-in shared preview lasts three days. If it has expired, publish again or choose **Keep it online** above.
+
+
+
+
+Publishing says my project is too large
+
+The built-in preview supports up to 500 files. Make a folder containing only the website files you want visitors to see. Leave dependency folders such as `node_modules` out of that copy, then open and publish it.
+
+
+
+A PHP application or a Python web server needs hosting that can run that program. The static-site steps here are for HTML websites.
diff --git a/docs/10-Tutorials/04-bootstrap.md b/docs/10-Tutorials/04-bootstrap.md
new file mode 100644
index 000000000..53e4d449d
--- /dev/null
+++ b/docs/10-Tutorials/04-bootstrap.md
@@ -0,0 +1,128 @@
+---
+title: Build a page with Bootstrap
+slug: /tutorials/bootstrap
+description: Open a Bootstrap starter page, make its button green, and test its layout. A guided exercise for Community and Phoenix Pro users.
+toc_max_heading_level: 2
+---
+
+import Tabs from '@theme/Tabs';
+import TabItem from '@theme/TabItem';
+import TutorialIcon from '@site/src/components/TutorialIcon';
+
+Build a page with a button that opens and closes a message. You'll then make the button green and check the page at a narrow screen width.
+
+Bootstrap supplies the page's ready-made styles. This exercise works in Community (free) and Phoenix Pro. Keep an internet connection: the starter loads Bootstrap from the web.
+
+## 1. Open the starter page
+
+1. [Download the Bootstrap starter](/tutorials/bootstrap-starter.zip).
+2. Extract the ZIP.
+3. In Phoenix Code, choose **Open Folder** and open the extracted `bootstrap-starter` folder.
+4. Click `index.html` in the file list.
+5. Click the to open Live Preview.
+
+**You should see** “Hello from Phoenix Code”, two sections called **Build** and **Preview**, and a blue **Show a tip** button.
+
+If Phoenix Code asks whether you trust this starter project, click **Trust & Execute Preview** to open it.
+
+## 2. Try the button
+
+1. Click in the preview toolbar.
+2. In the new browser window, click **Show a tip**.
+3. Check that a bordered message appears.
+4. Click the button again. The message should disappear.
+
+Keep this browser window open. You'll use it again after changing the button.
+
+## 3. Make the button green
+
+Choose your edition below.
+
+
+
+
+1. Click the in Phoenix Code's Live Preview toolbar to enter **Design Mode**. If the editor is already hidden, keep this view.
+2. If the in the preview toolbar is gray, click it to turn on **Edit Mode**. An means visual editing is on.
+3. Click **Show a tip** once to select the button.
+4. Click the section showing `button` in its floating toolbar. This opens **Element Properties**.
+5. Under **Class**, click the **×** on `btn-primary` to remove it.
+6. Click the , type `btn-success`, and press **Enter**. Keep the `btn` class.
+7. Click the in the narrow toolbar to the left of the preview. Its tooltip says **Save File**.
+
+Design Mode gives the preview more room; Edit Mode enables visual changes. You can stay in Design Mode while saving.
+
+[](/tutorials/media/bootstrap-pro-classes.png)
+
+Click the to turn visual editing off and try your green button while staying in Design Mode.
+
+[](/tutorials/media/bootstrap-pro-design-mode.png)
+
+
+
+
+1. Return to `index.html` in Phoenix Code. If the preview fills the app, click its to show the editor again.
+2. In the Live Preview toolbar, click the and choose **Highlight Mode**.
+3. Click **Show a tip** in the preview inside Phoenix Code. The editor moves to its `
+
+
+**You should see a green button.** Return to the separate browser window and reload it. Click the button to check that it still opens the message.
+
+## 4. Try a smaller screen
+
+Make the separate browser window narrower. **Build** and **Preview** should move from two columns to one above the other.
+
+If you have Pro, find the at the right end of the Live Preview toolbar. Click the beside the device icon and choose a phone size. The device icon changes to match the current preview width. See [Device Preview](/docs/Pro%20Features/device-preview).
+
+**You've changed a Bootstrap component and checked its layout.** Next, [add a page link](/docs/tutorials/link-pages) or [share your website](/docs/tutorials/share-website).
+
+## Need help?
+
+
+Clicking the button doesn't find its code
+
+Keep `index.html` open and choose **Highlight Mode** in Phoenix Code's preview toolbar. If the preview fills the app, click the to show the editor again.
+
+You can also press **Ctrl+F** on Windows/Linux or **Cmd+F** on macOS and search for `btn-primary` in `index.html`.
+
+
+
+
+The page looks like plain text
+
+Check your internet connection, then reload the preview. The starter uses Bootstrap 5.3.8 from an online file service. If your network blocks it, use Bootstrap's [compiled download](https://getbootstrap.com/docs/5.3/getting-started/download/) to work with local files.
+
+
+
+
+The button looks right but doesn't open the message
+
+Test it in the separate browser window. Edit Mode uses clicks to select the button.
+
+If it still doesn't work, check that you kept the `
+ }
+
+ {failed &&
+ This video couldn’t load. Follow the written steps below
+ {source?.props.src && <>, or open the video directly>}.
+
}
+ >;
+}
diff --git a/static/robots.txt b/static/robots.txt
index 795587ff8..43ed80943 100644
--- a/static/robots.txt
+++ b/static/robots.txt
@@ -6,29 +6,32 @@
# use of robots or failure to obey the robots exclusion standards set
# forth at http://www.robotstxt.org/ is strictly prohibited.
+# Docusaurus serves public styles, scripts, and screenshots under /assets/.
+# Crawlers need these resources to render and understand the documentation.
+
# Details about Googlebot available at: http://www.google.com/bot.html
# The Google search engine can see everything
User-agent: gsa-crawler-www
-Disallow: /assets/
+Allow: /assets/
# The Omniture search engine can see everything
User-agent: Atomz/1.0
-Disallow: /assets/
+Allow: /assets/
User-agent: *
-Disallow: /assets/
+Allow: /assets/
User-agent: AdsBot-Google
-Disallow: /assets/
+Allow: /assets/
User-agent: AdsBot-Google-Mobile
-Disallow: /assets/
+Allow: /assets/
User-agent: SearchmetricsBot
-Disallow: /assets/
+Allow: /assets/
User-agent: Googlebot
-Disallow: /assets/
+Allow: /assets/
# XML sitemaps
Sitemap: https://docs.phcode.dev/sitemap.xml
diff --git a/static/tutorials/bootstrap-starter.zip b/static/tutorials/bootstrap-starter.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e288a5860336c7541fbc73fbd5713514c0c5619a
GIT binary patch
literal 943
zcmWIWW@Zs#U|`??V#Syx|1(yIGBYq-Vr5{E0g5E$=a&?h6eSku7MCOzm82HwXXd4(
zR_JAvCb0K;c+SmaAH!`=J>GT93hRvZo@VU#xNy-Oha^`gCPpdlprpE5
z#-J@zJ!d=f$xQm)x}872{FC(cmAPImcf^W*Wj%^ln0e|EL+AtE6Fl$ZXo3
z^xqzdIsC^2#Zwkfd2!TGqeaTXn}ID=W>iL0bab>i@A54H`UtMUOvnE(WlGKZa39E$|DSFPq1#iOA&ewZ)RL^NC?mS#uCKBkke#eFc+h?=ecQ4&N|NX6;je@HMWzrtAt}y#_124*hTkau^CkG5RC0o=W#_KR^;aD0jYO_#3bXuQ=XC$u
zW*On!9m;24oJwxEwEE}4%{NQ;UrzI$kZ@{_U-Yc_CA$(#e@~GLj1phF!=>QYgjqYS
z+=bps&UL974`r9wA3Fv?Sy?p)s`GLO-XWGAc{(ry4oRV91f7o7z
wwO>x#eegePfHxzP2s7>s1
+
+
+
+
+ My Bootstrap page
+
+
+
+
+
Hello from Phoenix Code
+
This page uses Bootstrap for its layout, spacing, and button.
+
+
+
Build
+
Edit this HTML in Phoenix Code and save your changes.
+
+
+
Preview
+
Make the browser narrow to see these columns stack.
+
+
+
+
+
The button works because the Bootstrap JavaScript bundle is loaded.