如何更改 confluence 的 table-plus 宏中的列宽?

发布于 2025-01-01 17:55:41 字数 548 浏览 2 评论 0 原文

我尝试更改 Confluence wiki 标记中的列宽,但我不明白为什么它不起作用。我有这样的事情:

{table-plus:columnTypes=S,-,.|autoNumber=true|sortColumn=3 
|columnAttributes=,,style="background:yellow; font-size:14pt;"} 
|| Name || Phone || TCP || 
| John | 555-1234 | 192.168.1.10 | 
| Mary | 555-2134 | 192.168.1.12 | 
| Bob | 555-4527 | 192.168.1.9 | 

{table-plus}

我知道“columnAttributes”属性将 CSS 添加到单元格(根据此 链接),但在 Confluence 3.5 中,它在我的情况下不起作用。

I tried to change columns width in Confluence wiki markup, but I can't understand why it's not working. I have something like this:

{table-plus:columnTypes=S,-,.|autoNumber=true|sortColumn=3 
|columnAttributes=,,style="background:yellow; font-size:14pt;"} 
|| Name || Phone || TCP || 
| John | 555-1234 | 192.168.1.10 | 
| Mary | 555-2134 | 192.168.1.12 | 
| Bob | 555-4527 | 192.168.1.9 | 

{table-plus}

I know that "columnAttributes" attribute adds CSS to cells (according to this link), but in confluence 3.5 it's not working in my case.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

可爱暴击 2025-01-08 17:55:41

以下是设置每列宽度的语法,为了便于阅读而进行了格式化。 (请记住,宏不能包含空格。):

{table-plus:columnTypes=S,-,.
 |autoNumber=true|sortColumn=3|width=100%
 |columnAttributes=
    style="background:yellow;font-size:14pt;style=width:33%",
    style="background:yellow;font-size:14pt;style=width:33%",
    style="background:yellow;font-size:14pt;style=width:33%"
}

|| Name     || Phone   || TCP         || 
| John      | 555-1234 | 192.168.1.10 | 
| Mary      | 555-2134 | 192.168.1.12 | 
| Bob       | 555-4527 | 192.168.1.9  | 

{table-plus}

这会产生:
输入图片此处描述

Here's the syntax for setting the width in each column, formatted for readability. (Remember that macros must contain no whitespace.):

{table-plus:columnTypes=S,-,.
 |autoNumber=true|sortColumn=3|width=100%
 |columnAttributes=
    style="background:yellow;font-size:14pt;style=width:33%",
    style="background:yellow;font-size:14pt;style=width:33%",
    style="background:yellow;font-size:14pt;style=width:33%"
}

|| Name     || Phone   || TCP         || 
| John      | 555-1234 | 192.168.1.10 | 
| Mary      | 555-2134 | 192.168.1.12 | 
| Bob       | 555-4527 | 192.168.1.9  | 

{table-plus}

This produces:
enter image description here

烈酒灼喉 2025-01-08 17:55:41

使用 table-plus 宏,如您的链接中所述:

{table-plus:width=100%|columnAttributes=style=width:33%, style=width:33%, style=width:33%}

Use table-plus macro, as described in your link:

{table-plus:width=100%|columnAttributes=style=width:33%, style=width:33%, style=width:33%}
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文