Title: GT Table Block
Author: Birgit Pauli-Haack
Published: <strong>2026 年 5 月 4 日</strong>
Last modified: 2026 年 5 月 19 日

---

搜尋外掛

![](https://ps.w.org/gt-table-block/assets/banner-772x250.png?rev=3524138)

![](https://ps.w.org/gt-table-block/assets/icon-256x256.png?rev=3524138)

# GT Table Block

 由 [Birgit Pauli-Haack](https://profiles.wordpress.org/bph/) 開發

[下載](https://downloads.wordpress.org/plugin/gt-table-block.0.2.0.zip)

[即時預覽](https://tw.wordpress.org/plugins/gt-table-block/?preview=1)

 * [詳細資料](https://tw.wordpress.org/plugins/gt-table-block/#description)
 * [使用者評論](https://tw.wordpress.org/plugins/gt-table-block/#reviews)
 *  [安裝方式](https://tw.wordpress.org/plugins/gt-table-block/#installation)
 * [開發資訊](https://tw.wordpress.org/plugins/gt-table-block/#developers)

 [技術支援](https://wordpress.org/support/plugin/gt-table-block/)

## 外掛說明

GT Table Block extends the built-in `core/table` block with optional features that
compose cleanly — each feature is an independent toggle, not a block style, so any
combination can be active on the same table.

**Available in this release:**

 * **Sticky header row** — the `<thead>` row pins to the top of the viewport while
   the table body scrolls. Includes a numeric offset control for sites with a fixed
   admin bar or site header. Pure CSS at runtime (no frontend JavaScript). The sticky
   background is an opaque CSS variable with full theme.json customization support(
   see FAQ below).
 * **Styled first column** — gives the first column the same visual weight as the
   header row (bold, optional themeable background) and adds `scope="row"` to those
   cells in the saved markup so screen readers announce them as row headers. Addresses
   Gutenberg core issue #1470 (open since 2017). Pure CSS for the styling; the a11y
   attribute is added at save time only, so the editor preview stays unchanged.

**Planned for future releases:**

 * Sticky first column for wide tables with horizontal scroll — v0.3.0.
 * Merge / unmerge cells via a block toolbar control — v0.4.0.

#### Why a variation, not a replacement block?

The plugin deliberately extends `core/table` rather than forking it, so existing
tables stay compatible with core as it evolves. Independent boolean attributes also
let any combination of features be active at once — which block styles (a mutually
exclusive radio group) cannot offer.

### Source code

Source code, build tools, issue tracker, and development log: https://github.com/
bph/gt-table-block

The plugin is built with `@wordpress/scripts` (see the repository’s README for build
instructions). Each tagged release on GitHub corresponds to the stable tag published
here.

## 安裝方式

 1. Upload the plugin folder to `/wp-content/plugins/` or install via the Plugins screen.
 2. Activate through the **Plugins** menu.
 3. Insert the **Enhanced Table** variation from the block inserter, or convert an 
    existing Table block via the Block Settings panel.

## 常見問題集

### Does it replace the core Table block?

No. It registers a variation. Existing core Table blocks are unaffected until you
enable a feature toggle on them.

### Does it need frontend JavaScript?

No. Sticky header, header column styling, and sticky first column are pure CSS. 
Only the editor ships JS.

### Does it work with block themes?

Yes. It targets `core/table` and uses the `wp-block-table` class chain for specificity
without `!important`.

### How do I change the sticky header background color?

The sticky header is painted with an opaque background so body rows don’t show through
it. It resolves in this order:

 1. `--gt-sticky-header-bg` — a per-block or local override (wins over everything).
 2. `--wp--custom--gt-sticky-header-bg` — a theme.json `settings.custom` value.
 3. `Canvas` — the CSS system color (browser document background, adapts to light/dark
    mode).

**Theme-wide via theme.json (literal color):**

    ```
    { "settings": { "custom": { "gtStickyHeaderBg": "#f5f5f5" } } }
    ```

**Theme-wide via theme.json (reference a theme preset):**

    ```
    { "settings": { "custom": { "gtStickyHeaderBg": "var(--wp--preset--color--base)" } } }
    ```

The value is emitted into the CSS variable as-is, so any WP-generated preset works—`--
wp--preset--color--accent`, `--wp--preset--color--contrast-2`, or any palette slug
your theme registers.

In both cases WordPress serializes `settings.custom.gtStickyHeaderBg` as the CSS
variable `--wp--custom--gt-sticky-header-bg`, which the plugin reads as a fallback.

**Theme-wide via raw CSS in theme.json:**

    ```
    { "styles": { "css": ".wp-block-table.has-sticky-header { --gt-sticky-header-bg: var(--wp--preset--color--base); } " } }
    ```

**Per-block override:** add an inline style or Additional CSS class that sets `--
gt-sticky-header-bg` on the `<figure>`.

## 使用者評論

這個外掛目前沒有任何使用者評論。

## 參與者及開發者

以下人員參與了開源軟體〈GT Table Block〉的開發相關工作。

參與者

 *   [ Birgit Pauli-Haack ](https://profiles.wordpress.org/bph/)

[將〈GT Table Block〉外掛本地化為台灣繁體中文版](https://translate.wordpress.org/projects/wp-plugins/gt-table-block)

### 對開發相關資訊感興趣？

任何人均可[瀏覽程式碼](https://plugins.trac.wordpress.org/browser/gt-table-block/)、
查看 [SVN 存放庫](https://plugins.svn.wordpress.org/gt-table-block/)，或透過 [RSS](https://plugins.trac.wordpress.org/log/gt-table-block/?limit=100&mode=stop_on_copy&format=rss)
訂閱[開發記錄](https://plugins.trac.wordpress.org/log/gt-table-block/)。

## 變更記錄

#### 0.2.0

 * New feature: **Style first column**. Toggle in the Enhanced Table panel makes
   the first body/foot cells bold and adds `scope="row"` to them in the saved HTML
   for screen-reader semantics (Gutenberg #1470). Includes a colour picker for the
   column background, or theme-wide via the `--gt-first-column-bg` CSS variable.

#### 0.1.1

 * Documentation: shorter Short Description (Plugin Check 150-char limit), align
   GitHub README with readme.txt scope. No code changes.

#### 0.1.0

 * Initial release — sticky header row with optional offset control. Further features
   ship in subsequent releases.

## 中繼資料

 *  版本 **0.2.0**
 *  最後更新 **1 個月前**
 *  啟用安裝數 **100+**
 *  WordPress 版本需求 ** 6.6 或更新版本 **
 *  已測試相容的 WordPress 版本 **6.9.4**
 *  PHP 版本需求 ** 7.4 或更新版本 **
 *  語言
 * [English (US)](https://wordpress.org/plugins/gt-table-block/)
 * 標籤:
 * [block](https://tw.wordpress.org/plugins/tags/block/)[block-editor](https://tw.wordpress.org/plugins/tags/block-editor/)
   [gutenberg](https://tw.wordpress.org/plugins/tags/gutenberg/)[table](https://tw.wordpress.org/plugins/tags/table/)
 *  [進階檢視](https://tw.wordpress.org/plugins/gt-table-block/advanced/)

## 評分

這個項目尚無任何評論記錄。

[Your review](https://wordpress.org/support/plugin/gt-table-block/reviews/#new-post)

[查看全部使用者評論](https://wordpress.org/support/plugin/gt-table-block/reviews/)

## 參與者

 *   [ Birgit Pauli-Haack ](https://profiles.wordpress.org/bph/)

## 技術支援

最近 2 個月解決的問題:

     總計 4 個問題，已解決 1 個

 [檢視技術支援論壇](https://wordpress.org/support/plugin/gt-table-block/)