gpt4 book ai didi

css - formtastic 按钮上的 CSS 样式问题

转载 作者:行者123 更新时间:2023-11-28 12:26:18 25 4
gpt4 key购买 nike

如果我有一个带有 CSS 重写的 formtastic 按钮:

-f.buttons do
=f.commit_button :button_html => { :class => 'button positive' }

我在浏览器中看到呈现的样式为“按钮肯定更新”。我如何让它只反射(reflect)我想使用的 CSS 类并转储“更新”类?

最佳答案

不行,是part of formtastic

button_html.merge!(:class => [button_html[:class], key].compact.join(' '))

key 是 'create' 或 'update' 字符串。

关于css - formtastic 按钮上的 CSS 样式问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5714089/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com