Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 65 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: Docs

on:
push:
branches:
- main
workflow_dispatch:

permissions:
contents: read

concurrency:
group: docs-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v6
with:
persist-credentials: false

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.12"

- name: Set up Quarto
uses: quarto-dev/quarto-actions/setup@v2

- name: Configure GitHub Pages
uses: actions/configure-pages@v5

- name: Install package and demo dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -e ".[demo]"

- name: Build Great Docs site
env:
PYTHONIOENCODING: utf-8
PYTHONUTF8: "1"
run: python scripts/build_great_docs.py

- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v4
with:
path: great-docs/_site/

deploy:
needs: build
if: github.ref == format('refs/heads/{0}', github.event.repository.default_branch)
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
116 changes: 116 additions & 0 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
name: Publish Release

on:
pull_request_target:
branches:
- main
types:
- closed

permissions:
contents: write

concurrency:
group: publish-release-${{ github.event.pull_request.number }}
cancel-in-progress: false

jobs:
publish:
if: ${{ github.event.pull_request.merged == true }}
runs-on: ubuntu-latest
environment:
name: pypi
steps:
- name: Check out main
uses: actions/checkout@v6
with:
ref: ${{ github.event.pull_request.base.ref }}
fetch-depth: 0

- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: "20"
cache: npm

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.12"

- name: Validate release request
id: release
env:
PR_TITLE: ${{ github.event.pull_request.title }}
PR_BASE_REF: ${{ github.event.pull_request.base.ref }}
PR_HEAD_REF: ${{ github.event.pull_request.head.ref }}
shell: bash
run: |
version="$(python scripts/validate_release_pr.py --allow-current-version --print-version)"
echo "version=$version" >> "$GITHUB_OUTPUT"

- name: Apply release version
env:
PR_TITLE: ${{ github.event.pull_request.title }}
RELEASE_DATE: ${{ github.event.pull_request.merged_at }}
shell: bash
run: |
export RELEASE_DATE="${RELEASE_DATE%%T*}"
python scripts/apply_release_version.py

- name: Install Node dependencies
run: npm ci --legacy-peer-deps

- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt -r tests/requirements.txt

- name: Build and verify release artifacts
run: python scripts/check_release.py

- name: Ensure PyPI token is configured
env:
PYPI_API_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
shell: bash
run: |
if [ -z "${PYPI_API_TOKEN}" ]; then
echo "Missing PYPI_API_TOKEN secret in the 'pypi' environment." >&2
exit 1
fi

- name: Commit release metadata
shell: bash
run: |
if git diff --quiet -- package.json package-lock.json dash_mantine_datatable/package-info.json Project.toml CHANGELOG.md; then
exit 0
fi

git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add package.json package-lock.json dash_mantine_datatable/package-info.json Project.toml CHANGELOG.md
git commit -m "chore: release v${{ steps.release.outputs.version }}"
git push origin "HEAD:${{ github.event.pull_request.base.ref }}"

- name: Publish package to PyPI
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: python -m twine upload --skip-existing dist/*

- name: Generate GitHub release notes
run: python scripts/extract_release_notes.py "${{ steps.release.outputs.version }}" > "$RUNNER_TEMP/release-notes.md"

- name: Create or update GitHub release
env:
GH_TOKEN: ${{ github.token }}
RELEASE_TAG: v${{ steps.release.outputs.version }}
RELEASE_TITLE: ${{ github.event.pull_request.title }}
shell: bash
run: |
release_target="$(git rev-parse HEAD)"
if gh release view "$RELEASE_TAG" >/dev/null 2>&1; then
gh release edit "$RELEASE_TAG" --target "$release_target" --title "$RELEASE_TITLE" --notes-file "$RUNNER_TEMP/release-notes.md"
else
gh release create "$RELEASE_TAG" --target "$release_target" --title "$RELEASE_TITLE" --notes-file "$RUNNER_TEMP/release-notes.md"
fi
40 changes: 40 additions & 0 deletions .github/workflows/release-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Release PR Guard

on:
pull_request:
branches:
- main
types:
- opened
- edited
- reopened
- synchronize
- ready_for_review

permissions:
contents: read

concurrency:
group: release-pr-${{ github.event.pull_request.number }}
cancel-in-progress: true

jobs:
validate-release-pr:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v6
with:
persist-credentials: false

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.12"

- name: Validate staging release PR
env:
PR_TITLE: ${{ github.event.pull_request.title }}
PR_BASE_REF: ${{ github.base_ref }}
PR_HEAD_REF: ${{ github.head_ref }}
run: python scripts/validate_release_pr.py
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ node_modules/
pytest-cache-files-*/
pytest-tmp/
site/
great-docs/_site/
great-docs/.quarto/
great-docs/**/*.quarto_ipynb
venv/
*.egg-info/
*.log
Expand Down
26 changes: 19 additions & 7 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,25 @@

## Unreleased

- Added GitHub Actions to validate `staging -> main` release pull requests and
publish releases to PyPI and GitHub after merge.
- Made the release pull request title the source of truth for the next package
version, with automated version stamping and changelog promotion during the
publish workflow.
- Documented the staging-based release flow and the local release preflight
steps for contributors and maintainers.
### Added

- Great Docs site with user guide, recipes, and API reference, published to GitHub Pages.
- Recipe generator (`scripts/generate_recipes.py`) that keeps docs examples aligned with `usage.py`.
- Documentation media capture helper for README and recipe screenshots.
- Restored GitHub Actions for docs deployment, release PR validation, and PyPI publishing.

### Changed

- README refreshed with docs link, badges, feature overview, and example media.
- GitHub Pages docs workflow now builds the Quarto Great Docs site instead of pdoc-only output.

### Fixed

- Dash template rendering for grouped hierarchy cells and expansion chevrons.
- Filter popover dismissal for MultiSelect, Select, DateInput, and Autocomplete controls.
- Array-valued cell display formatting for filter and presentation columns.
- Table min-height row stretch behavior in fixed-height layouts.
- Inline editor and filter `setProps` synchronization for Dash Mantine controls.

## 0.1.0 - 2026-04-07

Expand Down
10 changes: 10 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,18 @@ npm run build:js
npm run build:backends
python -m pytest
python usage.py
python scripts/generate_recipes.py
python scripts/build_great_docs.py
python scripts/capture_docs_media.py
```

## Documentation

- Public docs are built from `great-docs/` with Quarto via `python scripts/build_great_docs.py`.
- Recipe pages are generated from `usage.py` via `python scripts/generate_recipes.py`.
- Screenshots for README and recipes come from `python scripts/capture_docs_media.py` while `usage.py` is running.
- `.github/workflows/docs.yml` publishes `great-docs/_site` to GitHub Pages on every `main` push.

## Branch workflow

- Create feature branches from `staging`.
Expand Down
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: dashMantineDatatable
Title: Mantine DataTable for Dash
Version: 0.0.1
Version: 0.1.0
Description: Dash bindings for Mantine DataTable with Dash-friendly helpers and component templates.
Depends: R (>= 3.0.2)
Imports:
Expand Down
Loading
Loading