You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2022/05/09 06:33:05 UTC
[GitHub] [echarts] Mr-Lixiaoqaing opened a new issue, #16997: 关于rich中预定义样式的优化
Mr-Lixiaoqaing opened a new issue, #16997:
URL: https://github.com/apache/echarts/issues/16997
### What problem does this feature solve?
formatter中使用rich,只能先在rich中定义好富文本对象,再在formatter中去使用(比如'{a|这段文本能使用a样式}')。
希望能在formatter中使用一个计算出来的样式对象,比如 '{a|这段文本能使用a样式}' 这个a不再是预定义在rich中的对象,而是可以在formatter函数中定义的一个对象。这样在使用一些动态的字体颜色、背景色等会方便很多
### What does the proposed API look like?

这是我想象中的样子。当formatter中没有定义a时,就使用rich中的a
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] echarts-bot[bot] commented on issue #16997: 关于rich中预定义样式的优化
Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-1120696866
@Mr-Lixiaoqaing It seems you are not using English, I've helped translate the content automatically. To make your issue understood by more people and get helped, we'd like to suggest using English next time. 🤗
<details><summary><b>TRANSLATED</b></summary><br>
**TITLE**
About the optimization of predefined styles in rich
**BODY**
### What problem does this feature solve?
The rich can only be used in the formatter to define a rich text object in rich and then use it in format (e.g. '{a| this text can use a style}').
It is desirable to use a computed style object in formatter, such as '{a| this text can use a style}' This a is no longer an object predefined in rich, but an object that can be defined in the formatr function. This will be much more convenient in using some dynamic font colors, background colors, etc
### What does the proposed API look like?

This is what I imagined. When a is not defined in formatter, a in rich is used
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Mr-Lixiaoqaing commented on issue #16997: 关于rich中预定义样式的优化
Posted by GitBox <gi...@apache.org>.
Mr-Lixiaoqaing commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-1121771597
是的,大部分场景使用预定义的样式是够用了。但是能让它更好用不是更好吗
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] nelsonbbarriento23 commented on issue #16997: 关于rich中预定义样式的优化
Posted by GitBox <gi...@apache.org>.
nelsonbbarriento23 commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-1120697254
Reopen please
On Mon, May 9, 2022, 12:32 AM echarts-bot[bot] ***@***.***>
wrote:
> I'm sorry to close this issue for it lacks the necessary title. Please
> provide *a descriptive and as concise as possible title to describe your
> problems or requests* and then the maintainers or I will reopen this
> issue.
>
> Every good bug report or feature request starts with a title. Your issue
> title is a critical element as it's the first thing maintainers see.
>
> A good issue title makes it easier for maintainers to understand what the
> issue is, easily locate it, and know what steps they'll need to take to fix
> it.
>
> Moreover, it's better to include keywords, as this makes it easier to find
> the issue self and similar issues in searches.
>
> —
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/echarts/issues/16997#issuecomment-1120695389>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AQXZRONAKDBO43IUQJ3TQN3VJCWO7ANCNFSM5VNGNKWQ>
> .
> You are receiving this because you are subscribed to this thread.Message
> ID: ***@***.***>
>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
Re: [I] 关于rich中预定义样式的优化 [echarts]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-2118382195
This issue has been automatically closed because it did not have recent activity. If this remains to be a problem with the latest version of Apache ECharts, please open a new issue and link this to it. Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] echarts-bot[bot] commented on issue #16997: [Feature]
Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-1120695389
I'm sorry to close this issue for it lacks the necessary title. Please provide **a _descriptive_ and as _concise_ as possible title to describe your problems or requests** and then the maintainers or I will reopen this issue.
Every good bug report or feature request starts with a title. Your issue title is a critical element as it's the first thing maintainers see.
A good issue title makes it easier for maintainers to understand what the issue is, easily locate it, and know what steps they'll need to take to fix it.
Moreover, it's better to include keywords, as this makes it easier to find the issue self and similar issues in searches.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] echarts-bot[bot] closed issue #16997: [Feature]
Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] closed issue #16997: [Feature]
URL: https://github.com/apache/echarts/issues/16997
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Ovilia commented on issue #16997: 关于rich中预定义样式的优化
Posted by GitBox <gi...@apache.org>.
Ovilia commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-1123252721
@Mr-Lixiaoqaing 你参考下楼上的做法,如果不满足的话,可以提一个 Pull Request 试试~
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
Re: [I] 关于rich中预定义样式的优化 [echarts]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #16997: 关于rich中预定义样式的优化
URL: https://github.com/apache/echarts/issues/16997
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] Ovilia commented on issue #16997: 关于rich中预定义样式的优化
Posted by GitBox <gi...@apache.org>.
Ovilia commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-1120728805
In most cases, it should be sufficient to use current implementation with several styles and set the name (like "a") dynamically.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
[GitHub] [echarts] li942475402 commented on issue #16997: 关于rich中预定义样式的优化
Posted by GitBox <gi...@apache.org>.
li942475402 commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-1122036912
动态的话
```javascript
formatter(value){
let map = {
valueA:richA,
valueB:richB,
...
}
return `{${map[valueA]}|${valueA}}`
}
rich:{
richA:{},
richB:{}
}
```
这样就可以吧
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org
Re: [I] 关于rich中预定义样式的优化 [echarts]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #16997:
URL: https://github.com/apache/echarts/issues/16997#issuecomment-2105269238
This issue has been automatically marked as stale because it did not have recent activity. It will be closed in 7 days if no further activity occurs. If you wish not to mark it as stale, please leave a comment in this issue.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org