primer_view_components 0.0.113 → 0.0.114

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,290 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Primer
4
+ module Beta
5
+ # Use `Markdown` to wrap markdown content.
6
+ class Markdown < Primer::Component
7
+ status :beta
8
+
9
+ DEFAULT_TAG = :div
10
+ TAG_OPTIONS = [DEFAULT_TAG, :article, :td].freeze
11
+ # @example Default
12
+ # <%= render(Primer::Beta::Markdown.new) do %>
13
+ # <p>Text can be <b>bold</b>, <i>italic</i>, or <s>strikethrough</s>. <a href="https://github.com">Links </a> should be blue with no underlines (unless hovered over).</p>
14
+ #
15
+ # <p>There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs.</p>
16
+ #
17
+ # <p>There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs.</p>
18
+ #
19
+ # <blockquote>
20
+ # <p>There should be no margin above this first sentence.</p>
21
+ # <p>Blockquotes should be a lighter gray with a gray border along the left side.</p>
22
+ # <p>There should be no margin below this final sentence.</p>
23
+ # </blockquote>
24
+ #
25
+ # <h1>Header 1</h1>
26
+ #
27
+ # <p>This is a normal paragraph following a header. Bacon ipsum dolor sit amet t-bone doner shank drumstick, pork belly porchetta chuck sausage brisket ham hock rump pig. Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.</p>
28
+ #
29
+ # <h2>Header 2</h2>
30
+ #
31
+ # <blockquote>This is a blockquote following a header. Bacon ipsum dolor sit amet t-bone doner shank drumstick, pork belly porchetta chuck sausage brisket ham hock rump pig. Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.</blockquote>
32
+ #
33
+ # <h3>Header 3</h3>
34
+ #
35
+ # <pre><code>This is a code block following a header.</code></pre>
36
+ #
37
+ # <h4>Header 4</h4>
38
+ #
39
+ # <ul>
40
+ # <li>This is an unordered list following a header.</li>
41
+ # <li>This is an unordered list following a header.</li>
42
+ # <li>This is an unordered list following a header.</li>
43
+ # </ul>
44
+ #
45
+ # <h5>Header 5</h5>
46
+ #
47
+ # <ol>
48
+ # <li>This is an ordered list following a header.</li>
49
+ # <li>This is an ordered list following a header.</li>
50
+ # <li>This is an ordered list following a header.</li>
51
+ # </ol>
52
+ #
53
+ # <h6>Header 6</h6>
54
+ #
55
+ # <table>
56
+ # <thead>
57
+ # <tr>
58
+ # <th>What</th>
59
+ # <th>Follows</th>
60
+ # </tr>
61
+ # </thead>
62
+ # <tbody>
63
+ # <tr>
64
+ # <td>A table</td>
65
+ # <td>A header</td>
66
+ # </tr>
67
+ # <tr>
68
+ # <td>A table</td>
69
+ # <td>A header</td>
70
+ # </tr>
71
+ # <tr>
72
+ # <td>A table</td>
73
+ # <td>A header</td>
74
+ # </tr>
75
+ # </tbody>
76
+ # </table>
77
+ #
78
+ # <hr />
79
+ #
80
+ # <p>There's a horizontal rule above and below this.</p>
81
+ #
82
+ # <hr />
83
+ #
84
+ # <p>Here is an unordered list:</p>
85
+ #
86
+ # <ul>
87
+ # <li>Salt-n-Pepa</li>
88
+ # <li>Bel Biv DeVoe</li>
89
+ # <li>Kid 'N Play</li>
90
+ # </ul>
91
+ #
92
+ # <p>And an ordered list:</p>
93
+ #
94
+ # <ol>
95
+ # <li>Michael Jackson</li>
96
+ # <li>Michael Bolton</li>
97
+ # <li>Michael Bublé</li>
98
+ # </ol>
99
+ #
100
+ # <p>And an unordered task list:</p>
101
+ #
102
+ # <ul>
103
+ # <li><input type="checkbox" id="create-markdown" checked /><label for="create-markdown">Create a sample markdown document</label><br></li>
104
+ # <li><input type="checkbox" id="tasks-list" checked /><label for="tasks-list">Add tasks list to it</label><br></li>
105
+ # <li><input type="checkbox" id="take-vacation" checked /><label for="take-vacation">Take a vacation</label><br></li>
106
+ # </ul>
107
+ #
108
+ # <p>And a "mixed" task list:</p>
109
+ #
110
+ # <ul>
111
+ # <li><input type="checkbox"id="steal-underpants"/><label for="steal-underpants">Steal underpants</label></li>
112
+ # <li>?</li>
113
+ # <li><input type="checkbox"id="profit"/><label for="profit">Profit!</label></li>
114
+ # </ul>
115
+ #
116
+ # And a nested list:
117
+ #
118
+ # <ul>
119
+ # <li>Jackson 5
120
+ # <ul>
121
+ # <li>Michael</li>
122
+ # <li>Tito</li>
123
+ # <li>Jackie</li>
124
+ # <li>Marlon</li>
125
+ # <li>Jermaine</li>
126
+ # </ul>
127
+ # </li>
128
+ # <li>TMNT
129
+ # <ul>
130
+ # <li>Leonardo</li>
131
+ # <li>Michelangelo</li>
132
+ # <li>Donatello</li>
133
+ # <li>Raphael</li>
134
+ # </ul>
135
+ # </li>
136
+ # </ul>
137
+ #
138
+ # <p>Definition lists can be used with HTML syntax. Definition terms are bold and italic.</p>
139
+ #
140
+ # <dl>
141
+ # <dt>Name</dt>
142
+ # <dd>Godzilla</dd>
143
+ # <dt>Born</dt>
144
+ # <dd>1952</dd>
145
+ # <dt>Birthplace</dt>
146
+ # <dd>Japan</dd>
147
+ # <dt>Color</dt>
148
+ # <dd>Green</dd>
149
+ # </dl>
150
+ #
151
+ # <hr />
152
+ #
153
+ # <p>Tables should have bold headings and alternating shaded rows.</p>
154
+ #
155
+ # <table>
156
+ # <thead>
157
+ # <tr>
158
+ # <th>Artist</th>
159
+ # <th>Album</th>
160
+ # <th>Year</th>
161
+ # </tr>
162
+ # </thead>
163
+ # <tbody>
164
+ # <tr>
165
+ # <td>David Bowie</td>
166
+ # <td>Scary Monsters</td>
167
+ # <td>1980</td>
168
+ # </tr>
169
+ # <tr>
170
+ # <td>Prince</td>
171
+ # <td>Purple Rain</td>
172
+ # <td>1982</td>
173
+ # </tr>
174
+ # <tr>
175
+ # <td>Beastie Boys</td>
176
+ # <td>License to Ill</td>
177
+ # <td>1986</td>
178
+ # </tr>
179
+ # <tr>
180
+ # <td>Janet Jackson</td>
181
+ # <td>Rhythm Nation 1814</td>
182
+ # <td>1989</td>
183
+ # </tr>
184
+ # </tbody>
185
+ # </table>
186
+ #
187
+ # <p>If a table is too wide, it should condense down and/or scroll horizontally.</p>
188
+ #
189
+ # <table>
190
+ # <thead>
191
+ # <tr>
192
+ # <th>Artist</th>
193
+ # <th>Album</th>
194
+ # <th>Year</th>
195
+ # <th>Label</th>
196
+ # <th>Songs</th>
197
+ # </tr>
198
+ # </thead>
199
+ # <tbody>
200
+ # <tr>
201
+ # <td>David Bowie</td>
202
+ # <td>Scary Monsters</td>
203
+ # <td>1980</td>
204
+ # <td>RCA Records</td>
205
+ # <td>It's No Game (No. 1), Up the Hill Backwards, Scary Monsters (And Super Creeps), Ashes to Ashes, Fashion, Teenage Wildlife, Scream Like a Baby, Kingdom Come, Because You're Young, It's No Game (No. 2)</td>
206
+ # </tr>
207
+ # <tr>
208
+ # <td>Prince</td>
209
+ # <td>Purple Rain</td>
210
+ # <td>1982</td>
211
+ # <td>Warner Brothers Records</td>
212
+ # <td>Let's Go Crazy, Take Me With U, The Beautiful Ones, Computer Blue, Darling Nikki, When Doves Cry, I Would Die 4 U, Baby I'm a Star, Purple Rain</td>
213
+ # </tr>
214
+ # <tr>
215
+ # <td>Beastie Boys</td>
216
+ # <td>License to Ill</td>
217
+ # <td>1986</td>
218
+ # <td>Def Jam</td>
219
+ # <td>Rhymin &amp; Stealin, The New Style, She's Crafty, Posse in Effect, Slow Ride, Girls, Fight for Your Right, No Sleep till Brooklyn, Paul Revere, "Hold It Now, Hit It", Brass Monkey, Slow and Low, Time to Get Ill</td>
220
+ # </tr>
221
+ # <tr>
222
+ # <td>Janet Jackson</td>
223
+ # <td>Rhythm Nation 1814</td>
224
+ # <td>1989</td>
225
+ # <td>A&amp;M</td>
226
+ # <td>Interlude: Pledge, Rhythm Nation, Interlude: T.V., State of the World, Interlude: Race, The Knowledge, Interlude: Let's Dance, Miss You Much, Interlude: Come Back, Love Will Never Do (Without You), Livin' in a World (They Didn't Make), Alright, Interlude: Hey Baby, Escapade, Interlude: No Acid, Black Cat, Lonely, Come Back to Me, Someday Is Tonight, Interlude: Livin'...In Complete Darkness</td>
227
+ # </tr>
228
+ # </tbody>
229
+ # </table>
230
+ #
231
+ # <hr />
232
+ #
233
+ # <p>Code snippets like <code>var foo = "bar";</code> can be shown inline.</p>
234
+ #
235
+ # <p>Also, <code>this should vertically align</code> <s><code>with this</code></s> <s>and this</s>.</p>
236
+ #
237
+ # <p>Code can also be shown in a block element.</p>
238
+ #
239
+ # <pre><code>var foo = "bar";</code></pre>
240
+ #
241
+ # <p>Code can also use syntax highlighting.</p>
242
+ #
243
+ # <pre><code>var foo = "bar";</code></pre>
244
+ #
245
+ # <pre tabindex="0"><code>Long, single-line code blocks should not wrap. They should horizontally scroll if they are too long. This line should be long enough to demonstrate this.</code></pre>
246
+ #
247
+ # <pre tabindex="0"><code>var foo = "The same thing is true for code with syntax highlighting. A single line of code should horizontally scroll if it is really long.";</code></pre>
248
+ #
249
+ # <p>Inline code inside table cells should still be distinguishable.</p>
250
+ #
251
+ # <table>
252
+ # <thead>
253
+ # <tr>
254
+ # <th>Language</th>
255
+ # <th>Code</th>
256
+ # </tr>
257
+ # </thead>
258
+ # <tbody>
259
+ # <tr>
260
+ # <td>JavasScript</td>
261
+ # <td><code>var foo = "bar";</code></td>
262
+ # </tr>
263
+ # <tr>
264
+ # <td>Ruby</td>
265
+ # <td><code>foo = "bar"</code></td>
266
+ # </tr>
267
+ # </tbody>
268
+ # </table>
269
+ #
270
+ # <pre><code>This is the final element on the page and there should be no margin below this.</code></pre>
271
+ # <% end %>
272
+ #
273
+ # @param tag [Symbol] <%= one_of(Primer::Beta::Markdown::TAG_OPTIONS) %>
274
+ # @param system_arguments [Hash] <%= link_to_system_arguments_docs %>
275
+ def initialize(tag: DEFAULT_TAG, **system_arguments)
276
+ @system_arguments = system_arguments
277
+ @system_arguments[:tag] = fetch_or_fallback(TAG_OPTIONS, tag, DEFAULT_TAG)
278
+
279
+ @system_arguments[:classes] = class_names(
280
+ "markdown-body",
281
+ system_arguments[:classes]
282
+ )
283
+ end
284
+
285
+ def call
286
+ render(Primer::BaseComponent.new(**@system_arguments)) { content }
287
+ end
288
+ end
289
+ end
290
+ end
@@ -1,288 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Primer
4
- # Use `Markdown` to wrap markdown content.
5
- class Markdown < Primer::Component
6
- status :beta
7
-
8
- DEFAULT_TAG = :div
9
- TAG_OPTIONS = [DEFAULT_TAG, :article, :td].freeze
10
- # @example Default
11
- # <%= render(Primer::Markdown.new) do %>
12
- # <p>Text can be <b>bold</b>, <i>italic</i>, or <s>strikethrough</s>. <a href="https://github.com">Links </a> should be blue with no underlines (unless hovered over).</p>
13
- #
14
- # <p>There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs.</p>
15
- #
16
- # <p>There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs.</p>
17
- #
18
- # <blockquote>
19
- # <p>There should be no margin above this first sentence.</p>
20
- # <p>Blockquotes should be a lighter gray with a gray border along the left side.</p>
21
- # <p>There should be no margin below this final sentence.</p>
22
- # </blockquote>
23
- #
24
- # <h1>Header 1</h1>
25
- #
26
- # <p>This is a normal paragraph following a header. Bacon ipsum dolor sit amet t-bone doner shank drumstick, pork belly porchetta chuck sausage brisket ham hock rump pig. Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.</p>
27
- #
28
- # <h2>Header 2</h2>
29
- #
30
- # <blockquote>This is a blockquote following a header. Bacon ipsum dolor sit amet t-bone doner shank drumstick, pork belly porchetta chuck sausage brisket ham hock rump pig. Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.</blockquote>
31
- #
32
- # <h3>Header 3</h3>
33
- #
34
- # <pre><code>This is a code block following a header.</code></pre>
35
- #
36
- # <h4>Header 4</h4>
37
- #
38
- # <ul>
39
- # <li>This is an unordered list following a header.</li>
40
- # <li>This is an unordered list following a header.</li>
41
- # <li>This is an unordered list following a header.</li>
42
- # </ul>
43
- #
44
- # <h5>Header 5</h5>
45
- #
46
- # <ol>
47
- # <li>This is an ordered list following a header.</li>
48
- # <li>This is an ordered list following a header.</li>
49
- # <li>This is an ordered list following a header.</li>
50
- # </ol>
51
- #
52
- # <h6>Header 6</h6>
53
- #
54
- # <table>
55
- # <thead>
56
- # <tr>
57
- # <th>What</th>
58
- # <th>Follows</th>
59
- # </tr>
60
- # </thead>
61
- # <tbody>
62
- # <tr>
63
- # <td>A table</td>
64
- # <td>A header</td>
65
- # </tr>
66
- # <tr>
67
- # <td>A table</td>
68
- # <td>A header</td>
69
- # </tr>
70
- # <tr>
71
- # <td>A table</td>
72
- # <td>A header</td>
73
- # </tr>
74
- # </tbody>
75
- # </table>
76
- #
77
- # <hr />
78
- #
79
- # <p>There's a horizontal rule above and below this.</p>
80
- #
81
- # <hr />
82
- #
83
- # <p>Here is an unordered list:</p>
84
- #
85
- # <ul>
86
- # <li>Salt-n-Pepa</li>
87
- # <li>Bel Biv DeVoe</li>
88
- # <li>Kid 'N Play</li>
89
- # </ul>
90
- #
91
- # <p>And an ordered list:</p>
92
- #
93
- # <ol>
94
- # <li>Michael Jackson</li>
95
- # <li>Michael Bolton</li>
96
- # <li>Michael Bublé</li>
97
- # </ol>
98
- #
99
- # <p>And an unordered task list:</p>
100
- #
101
- # <ul>
102
- # <li><input type="checkbox" id="create-markdown" checked /><label for="create-markdown">Create a sample markdown document</label><br></li>
103
- # <li><input type="checkbox" id="tasks-list" checked /><label for="tasks-list">Add tasks list to it</label><br></li>
104
- # <li><input type="checkbox" id="take-vacation" checked /><label for="take-vacation">Take a vacation</label><br></li>
105
- # </ul>
106
- #
107
- # <p>And a "mixed" task list:</p>
108
- #
109
- # <ul>
110
- # <li><input type="checkbox"id="steal-underpants"/><label for="steal-underpants">Steal underpants</label></li>
111
- # <li>?</li>
112
- # <li><input type="checkbox"id="profit"/><label for="profit">Profit!</label></li>
113
- # </ul>
114
- #
115
- # And a nested list:
116
- #
117
- # <ul>
118
- # <li>Jackson 5
119
- # <ul>
120
- # <li>Michael</li>
121
- # <li>Tito</li>
122
- # <li>Jackie</li>
123
- # <li>Marlon</li>
124
- # <li>Jermaine</li>
125
- # </ul>
126
- # </li>
127
- # <li>TMNT
128
- # <ul>
129
- # <li>Leonardo</li>
130
- # <li>Michelangelo</li>
131
- # <li>Donatello</li>
132
- # <li>Raphael</li>
133
- # </ul>
134
- # </li>
135
- # </ul>
136
- #
137
- # <p>Definition lists can be used with HTML syntax. Definition terms are bold and italic.</p>
138
- #
139
- # <dl>
140
- # <dt>Name</dt>
141
- # <dd>Godzilla</dd>
142
- # <dt>Born</dt>
143
- # <dd>1952</dd>
144
- # <dt>Birthplace</dt>
145
- # <dd>Japan</dd>
146
- # <dt>Color</dt>
147
- # <dd>Green</dd>
148
- # </dl>
149
- #
150
- # <hr />
151
- #
152
- # <p>Tables should have bold headings and alternating shaded rows.</p>
153
- #
154
- # <table>
155
- # <thead>
156
- # <tr>
157
- # <th>Artist</th>
158
- # <th>Album</th>
159
- # <th>Year</th>
160
- # </tr>
161
- # </thead>
162
- # <tbody>
163
- # <tr>
164
- # <td>David Bowie</td>
165
- # <td>Scary Monsters</td>
166
- # <td>1980</td>
167
- # </tr>
168
- # <tr>
169
- # <td>Prince</td>
170
- # <td>Purple Rain</td>
171
- # <td>1982</td>
172
- # </tr>
173
- # <tr>
174
- # <td>Beastie Boys</td>
175
- # <td>License to Ill</td>
176
- # <td>1986</td>
177
- # </tr>
178
- # <tr>
179
- # <td>Janet Jackson</td>
180
- # <td>Rhythm Nation 1814</td>
181
- # <td>1989</td>
182
- # </tr>
183
- # </tbody>
184
- # </table>
185
- #
186
- # <p>If a table is too wide, it should condense down and/or scroll horizontally.</p>
187
- #
188
- # <table>
189
- # <thead>
190
- # <tr>
191
- # <th>Artist</th>
192
- # <th>Album</th>
193
- # <th>Year</th>
194
- # <th>Label</th>
195
- # <th>Songs</th>
196
- # </tr>
197
- # </thead>
198
- # <tbody>
199
- # <tr>
200
- # <td>David Bowie</td>
201
- # <td>Scary Monsters</td>
202
- # <td>1980</td>
203
- # <td>RCA Records</td>
204
- # <td>It's No Game (No. 1), Up the Hill Backwards, Scary Monsters (And Super Creeps), Ashes to Ashes, Fashion, Teenage Wildlife, Scream Like a Baby, Kingdom Come, Because You're Young, It's No Game (No. 2)</td>
205
- # </tr>
206
- # <tr>
207
- # <td>Prince</td>
208
- # <td>Purple Rain</td>
209
- # <td>1982</td>
210
- # <td>Warner Brothers Records</td>
211
- # <td>Let's Go Crazy, Take Me With U, The Beautiful Ones, Computer Blue, Darling Nikki, When Doves Cry, I Would Die 4 U, Baby I'm a Star, Purple Rain</td>
212
- # </tr>
213
- # <tr>
214
- # <td>Beastie Boys</td>
215
- # <td>License to Ill</td>
216
- # <td>1986</td>
217
- # <td>Def Jam</td>
218
- # <td>Rhymin &amp; Stealin, The New Style, She's Crafty, Posse in Effect, Slow Ride, Girls, Fight for Your Right, No Sleep till Brooklyn, Paul Revere, "Hold It Now, Hit It", Brass Monkey, Slow and Low, Time to Get Ill</td>
219
- # </tr>
220
- # <tr>
221
- # <td>Janet Jackson</td>
222
- # <td>Rhythm Nation 1814</td>
223
- # <td>1989</td>
224
- # <td>A&amp;M</td>
225
- # <td>Interlude: Pledge, Rhythm Nation, Interlude: T.V., State of the World, Interlude: Race, The Knowledge, Interlude: Let's Dance, Miss You Much, Interlude: Come Back, Love Will Never Do (Without You), Livin' in a World (They Didn't Make), Alright, Interlude: Hey Baby, Escapade, Interlude: No Acid, Black Cat, Lonely, Come Back to Me, Someday Is Tonight, Interlude: Livin'...In Complete Darkness</td>
226
- # </tr>
227
- # </tbody>
228
- # </table>
229
- #
230
- # <hr />
231
- #
232
- # <p>Code snippets like <code>var foo = "bar";</code> can be shown inline.</p>
233
- #
234
- # <p>Also, <code>this should vertically align</code> <s><code>with this</code></s> <s>and this</s>.</p>
235
- #
236
- # <p>Code can also be shown in a block element.</p>
237
- #
238
- # <pre><code>var foo = "bar";</code></pre>
239
- #
240
- # <p>Code can also use syntax highlighting.</p>
241
- #
242
- # <pre><code>var foo = "bar";</code></pre>
243
- #
244
- # <pre tabindex="0"><code>Long, single-line code blocks should not wrap. They should horizontally scroll if they are too long. This line should be long enough to demonstrate this.</code></pre>
245
- #
246
- # <pre tabindex="0"><code>var foo = "The same thing is true for code with syntax highlighting. A single line of code should horizontally scroll if it is really long.";</code></pre>
247
- #
248
- # <p>Inline code inside table cells should still be distinguishable.</p>
249
- #
250
- # <table>
251
- # <thead>
252
- # <tr>
253
- # <th>Language</th>
254
- # <th>Code</th>
255
- # </tr>
256
- # </thead>
257
- # <tbody>
258
- # <tr>
259
- # <td>JavasScript</td>
260
- # <td><code>var foo = "bar";</code></td>
261
- # </tr>
262
- # <tr>
263
- # <td>Ruby</td>
264
- # <td><code>foo = "bar"</code></td>
265
- # </tr>
266
- # </tbody>
267
- # </table>
268
- #
269
- # <pre><code>This is the final element on the page and there should be no margin below this.</code></pre>
270
- # <% end %>
271
- #
272
- # @param tag [Symbol] <%= one_of(Primer::Markdown::TAG_OPTIONS) %>
273
- # @param system_arguments [Hash] <%= link_to_system_arguments_docs %>
274
- def initialize(tag: DEFAULT_TAG, **system_arguments)
275
- @system_arguments = system_arguments
276
- @system_arguments[:tag] = fetch_or_fallback(TAG_OPTIONS, tag, DEFAULT_TAG)
277
-
278
- @system_arguments[:classes] = class_names(
279
- "markdown-body",
280
- system_arguments[:classes]
281
- )
282
- end
283
-
284
- def call
285
- render(Primer::BaseComponent.new(**@system_arguments)) { content }
286
- end
4
+ class Markdown < Primer::Beta::Markdown
5
+ status :deprecated
287
6
  end
288
7
  end
@@ -20,7 +20,6 @@
20
20
  @import "./beta/blankslate.pcss";
21
21
  @import "./beta/breadcrumbs.pcss";
22
22
  @import "./beta/button.pcss";
23
- @import "./beta/button_group.pcss";
24
23
  @import "./beta/counter.pcss";
25
24
  @import "./beta/flash.pcss";
26
25
  @import "./beta/label.pcss";
@@ -30,7 +29,6 @@
30
29
  @import "./beta/truncate.pcss";
31
30
 
32
31
  /* to be renamed */
33
- @import "./button_component.pcss";
34
32
  @import "./menu_component.pcss";
35
33
  @import "./state_component.pcss";
36
34
  @import "./subhead_component.pcss";
@@ -59,6 +59,10 @@ deprecations:
59
59
  autocorrect: true
60
60
  replacement: "Primer::Beta::Link"
61
61
 
62
+ - component: "Primer::Markdown"
63
+ autocorrect: true
64
+ replacement: "Primer::Beta::Markdown"
65
+
62
66
  - component: "Primer::PopoverComponent"
63
67
  autocorrect: true
64
68
  replacement: "Primer::Beta::Popover"
@@ -6,7 +6,7 @@ module Primer
6
6
  module VERSION
7
7
  MAJOR = 0
8
8
  MINOR = 0
9
- PATCH = 113
9
+ PATCH = 114
10
10
 
11
11
  STRING = [MAJOR, MINOR, PATCH].join(".")
12
12
  end
data/lib/tasks/docs.rake CHANGED
@@ -67,7 +67,7 @@ namespace :docs do
67
67
  Primer::Beta::Label,
68
68
  Primer::LayoutComponent,
69
69
  Primer::Beta::Link,
70
- Primer::Markdown,
70
+ Primer::Beta::Markdown,
71
71
  Primer::MenuComponent,
72
72
  Primer::Navigation::TabComponent,
73
73
  Primer::OcticonComponent,
@@ -1,9 +1,10 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Primer
4
- # @label Markdown
5
- class MarkdownPreview < ViewComponent::Preview
6
- MD_FIXTURE = %(
4
+ module Beta
5
+ # @label Markdown
6
+ class MarkdownPreview < ViewComponent::Preview
7
+ MD_FIXTURE = %(
7
8
  <p>Text can be <b>bold</b>, <i>italic</i>, or <s>strikethrough</s>. <a href=\"https://github.com\">Links </a> should be blue with no underlines (unless hovered over).</p>
8
9
 
9
10
  <p>There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs.</p>
@@ -274,17 +275,18 @@ module Primer
274
275
  <pre><code>This is the final element on the page and there should be no margin below this.</code></pre>
275
276
  ).html_safe # rubocop:disable Rails/OutputSafety
276
277
 
277
- # @label Playground
278
- def playground
279
- render(Primer::Markdown.new) do
280
- MD_FIXTURE
278
+ # @label Playground
279
+ def playground
280
+ render(Primer::Beta::Markdown.new) do
281
+ MD_FIXTURE
282
+ end
281
283
  end
282
- end
283
284
 
284
- # @label Default Options
285
- def default
286
- render(Primer::Markdown.new) do
287
- MD_FIXTURE
285
+ # @label Default Options
286
+ def default
287
+ render(Primer::Beta::Markdown.new) do
288
+ MD_FIXTURE
289
+ end
288
290
  end
289
291
  end
290
292
  end