trycourier 6.7.0 → 6.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/README.md +1 -1
- data/lib/courier/models/elemental_action_node.rb +31 -3
- data/lib/courier/version.rb +1 -1
- data/rbi/courier/models/elemental_action_node.rbi +46 -3
- data/sig/courier/models/elemental_action_node.rbs +3 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5ed0341a28ac90163c1d29bdd7011d64d8fb6296b449a6d1ce17170f05fbc013
|
|
4
|
+
data.tar.gz: 884fc8993f5aadbd4250cd9d16d22c27792142dacd5ceae26d1679eab594e751
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 5f9ce02df1f3c0e222cbaeb03b6687fa3514a46226027d6850b3e168f1edfa390e5f7483044df2302bf606f85e90ea2d1e8b820da0dcf89f1137074f93bd819a
|
|
7
|
+
data.tar.gz: 36d2bee02a55f61397c3a3a1d770423e1d1bbeef1dd126600f9f65e3b7ec11b997f4a5c2c71c3e655d3a1927f9d9680603ade9a324e7a505a37420a7e5961932
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [6.8.0](https://github.com/trycourier/courier-ruby/compare/v6.7.0...v6.8.0) (2026-09-23)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **api:** publish the secondary and tertiary action styles [C-19961] ([#159](https://github.com/trycourier/courier-ruby/issues/159)) ([57cb2c8](https://github.com/trycourier/courier-ruby/commit/57cb2c80c80e9f84c140d573759d7d745e277d17))
|
|
9
|
+
|
|
3
10
|
## [6.7.0](https://github.com/trycourier/courier-ruby/compare/v6.6.0...v6.7.0) (2026-09-22)
|
|
4
11
|
|
|
5
12
|
|
data/README.md
CHANGED
|
@@ -73,7 +73,20 @@ module Courier
|
|
|
73
73
|
optional :padding, String, nil?: true
|
|
74
74
|
|
|
75
75
|
# @!attribute style
|
|
76
|
-
#
|
|
76
|
+
# How prominent the action should be. `button` is the default, `secondary` and
|
|
77
|
+
# `tertiary` are the other two button styles, and `link` renders as inline text
|
|
78
|
+
# rather than a button.
|
|
79
|
+
#
|
|
80
|
+
# Each channel draws these as closely as its medium allows. Email fills `button`,
|
|
81
|
+
# outlines `secondary`, and underlines `tertiary`. The in-app Inbox fills
|
|
82
|
+
# `button`, outlines `secondary`, and draws `tertiary` as a solid button. Slack
|
|
83
|
+
# renders all three as Block Kit buttons, with `secondary` in Slack's `primary`
|
|
84
|
+
# style and `tertiary` in its `danger` style.
|
|
85
|
+
#
|
|
86
|
+
# `background_color` is the fill for `button`, and the border and label color for
|
|
87
|
+
# `secondary`. For `tertiary` it colors the underline and label in email and the
|
|
88
|
+
# fill in the Inbox. It does not apply to `link`. An Inbox theme that sets its own
|
|
89
|
+
# action colors takes precedence over the template.
|
|
77
90
|
#
|
|
78
91
|
# @return [Symbol, Courier::Models::ElementalActionNode::Style, nil]
|
|
79
92
|
optional :style, enum: -> { Courier::ElementalActionNode::Style }, nil?: true
|
|
@@ -106,13 +119,28 @@ module Courier
|
|
|
106
119
|
#
|
|
107
120
|
# @param padding [String, nil] CSS padding applied to the action button. For example, `8px 16px`
|
|
108
121
|
#
|
|
109
|
-
# @param style [Symbol, Courier::Models::ElementalActionNode::Style, nil]
|
|
122
|
+
# @param style [Symbol, Courier::Models::ElementalActionNode::Style, nil] How prominent the action should be. `button` is the default, `secondary` and `te
|
|
110
123
|
|
|
111
|
-
#
|
|
124
|
+
# How prominent the action should be. `button` is the default, `secondary` and
|
|
125
|
+
# `tertiary` are the other two button styles, and `link` renders as inline text
|
|
126
|
+
# rather than a button.
|
|
127
|
+
#
|
|
128
|
+
# Each channel draws these as closely as its medium allows. Email fills `button`,
|
|
129
|
+
# outlines `secondary`, and underlines `tertiary`. The in-app Inbox fills
|
|
130
|
+
# `button`, outlines `secondary`, and draws `tertiary` as a solid button. Slack
|
|
131
|
+
# renders all three as Block Kit buttons, with `secondary` in Slack's `primary`
|
|
132
|
+
# style and `tertiary` in its `danger` style.
|
|
133
|
+
#
|
|
134
|
+
# `background_color` is the fill for `button`, and the border and label color for
|
|
135
|
+
# `secondary`. For `tertiary` it colors the underline and label in email and the
|
|
136
|
+
# fill in the Inbox. It does not apply to `link`. An Inbox theme that sets its own
|
|
137
|
+
# action colors takes precedence over the template.
|
|
112
138
|
module Style
|
|
113
139
|
extend Courier::Internal::Type::Enum
|
|
114
140
|
|
|
115
141
|
BUTTON = :button
|
|
142
|
+
SECONDARY = :secondary
|
|
143
|
+
TERTIARY = :tertiary
|
|
116
144
|
LINK = :link
|
|
117
145
|
|
|
118
146
|
# @!method self.values
|
data/lib/courier/version.rb
CHANGED
|
@@ -55,7 +55,20 @@ module Courier
|
|
|
55
55
|
sig { returns(T.nilable(String)) }
|
|
56
56
|
attr_accessor :padding
|
|
57
57
|
|
|
58
|
-
#
|
|
58
|
+
# How prominent the action should be. `button` is the default, `secondary` and
|
|
59
|
+
# `tertiary` are the other two button styles, and `link` renders as inline text
|
|
60
|
+
# rather than a button.
|
|
61
|
+
#
|
|
62
|
+
# Each channel draws these as closely as its medium allows. Email fills `button`,
|
|
63
|
+
# outlines `secondary`, and underlines `tertiary`. The in-app Inbox fills
|
|
64
|
+
# `button`, outlines `secondary`, and draws `tertiary` as a solid button. Slack
|
|
65
|
+
# renders all three as Block Kit buttons, with `secondary` in Slack's `primary`
|
|
66
|
+
# style and `tertiary` in its `danger` style.
|
|
67
|
+
#
|
|
68
|
+
# `background_color` is the fill for `button`, and the border and label color for
|
|
69
|
+
# `secondary`. For `tertiary` it colors the underline and label in email and the
|
|
70
|
+
# fill in the Inbox. It does not apply to `link`. An Inbox theme that sets its own
|
|
71
|
+
# action colors takes precedence over the template.
|
|
59
72
|
sig { returns(T.nilable(Courier::ElementalActionNode::Style::OrSymbol)) }
|
|
60
73
|
attr_accessor :style
|
|
61
74
|
|
|
@@ -102,7 +115,20 @@ module Courier
|
|
|
102
115
|
locales: nil,
|
|
103
116
|
# CSS padding applied to the action button. For example, `8px 16px`
|
|
104
117
|
padding: nil,
|
|
105
|
-
#
|
|
118
|
+
# How prominent the action should be. `button` is the default, `secondary` and
|
|
119
|
+
# `tertiary` are the other two button styles, and `link` renders as inline text
|
|
120
|
+
# rather than a button.
|
|
121
|
+
#
|
|
122
|
+
# Each channel draws these as closely as its medium allows. Email fills `button`,
|
|
123
|
+
# outlines `secondary`, and underlines `tertiary`. The in-app Inbox fills
|
|
124
|
+
# `button`, outlines `secondary`, and draws `tertiary` as a solid button. Slack
|
|
125
|
+
# renders all three as Block Kit buttons, with `secondary` in Slack's `primary`
|
|
126
|
+
# style and `tertiary` in its `danger` style.
|
|
127
|
+
#
|
|
128
|
+
# `background_color` is the fill for `button`, and the border and label color for
|
|
129
|
+
# `secondary`. For `tertiary` it colors the underline and label in email and the
|
|
130
|
+
# fill in the Inbox. It does not apply to `link`. An Inbox theme that sets its own
|
|
131
|
+
# action colors takes precedence over the template.
|
|
106
132
|
style: nil
|
|
107
133
|
)
|
|
108
134
|
end
|
|
@@ -128,7 +154,20 @@ module Courier
|
|
|
128
154
|
def to_hash
|
|
129
155
|
end
|
|
130
156
|
|
|
131
|
-
#
|
|
157
|
+
# How prominent the action should be. `button` is the default, `secondary` and
|
|
158
|
+
# `tertiary` are the other two button styles, and `link` renders as inline text
|
|
159
|
+
# rather than a button.
|
|
160
|
+
#
|
|
161
|
+
# Each channel draws these as closely as its medium allows. Email fills `button`,
|
|
162
|
+
# outlines `secondary`, and underlines `tertiary`. The in-app Inbox fills
|
|
163
|
+
# `button`, outlines `secondary`, and draws `tertiary` as a solid button. Slack
|
|
164
|
+
# renders all three as Block Kit buttons, with `secondary` in Slack's `primary`
|
|
165
|
+
# style and `tertiary` in its `danger` style.
|
|
166
|
+
#
|
|
167
|
+
# `background_color` is the fill for `button`, and the border and label color for
|
|
168
|
+
# `secondary`. For `tertiary` it colors the underline and label in email and the
|
|
169
|
+
# fill in the Inbox. It does not apply to `link`. An Inbox theme that sets its own
|
|
170
|
+
# action colors takes precedence over the template.
|
|
132
171
|
module Style
|
|
133
172
|
extend Courier::Internal::Type::Enum
|
|
134
173
|
|
|
@@ -138,6 +177,10 @@ module Courier
|
|
|
138
177
|
|
|
139
178
|
BUTTON =
|
|
140
179
|
T.let(:button, Courier::ElementalActionNode::Style::TaggedSymbol)
|
|
180
|
+
SECONDARY =
|
|
181
|
+
T.let(:secondary, Courier::ElementalActionNode::Style::TaggedSymbol)
|
|
182
|
+
TERTIARY =
|
|
183
|
+
T.let(:tertiary, Courier::ElementalActionNode::Style::TaggedSymbol)
|
|
141
184
|
LINK = T.let(:link, Courier::ElementalActionNode::Style::TaggedSymbol)
|
|
142
185
|
|
|
143
186
|
sig do
|
|
@@ -97,12 +97,14 @@ module Courier
|
|
|
97
97
|
style: Courier::Models::ElementalActionNode::style?
|
|
98
98
|
}
|
|
99
99
|
|
|
100
|
-
type style = :button | :link
|
|
100
|
+
type style = :button | :secondary | :tertiary | :link
|
|
101
101
|
|
|
102
102
|
module Style
|
|
103
103
|
extend Courier::Internal::Type::Enum
|
|
104
104
|
|
|
105
105
|
BUTTON: :button
|
|
106
|
+
SECONDARY: :secondary
|
|
107
|
+
TERTIARY: :tertiary
|
|
106
108
|
LINK: :link
|
|
107
109
|
|
|
108
110
|
def self?.values: -> ::Array[Courier::Models::ElementalActionNode::style]
|