Skip to content

Commit 2106624

Browse files
authored
📖 [Story sidebar] Removed sidebar from docs (ampproject#35616)
* removed sidebar and bookend docs * removed unused import * revert test removals * Add newline on visual test html
1 parent d21ecc0 commit 2106624

3 files changed

Lines changed: 1 addition & 80 deletions

File tree

extensions/amp-sidebar/0.1/amp-sidebar.md

Lines changed: 0 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22
$category@: layout
33
formats:
44
- websites
5-
- stories
65
- email
7-
- stories
86
teaser:
97
text: Provides a way to display meta content intended for temporary access such as navigation, links, buttons, menus.
108
---
@@ -261,55 +259,6 @@ When using `<amp-sidebar>`, keep in mind that your users will often view your pa
261259

262260
For this reason, we recommend that affordances to open the sidebar are not placed in a fixed, full-width header.
263261

264-
[filter formats="stories"]
265-
266-
### Sidebar for Stories
267-
268-
Use of `amp-sidebar` is supported within the `amp-story` [component](https://www.ampproject.org/stories/).
269-
270-
#### Behavior
271-
272-
- The `<amp-sidebar>` must be a direct child of `<amp-story>`.
273-
- The sidebar defaults to the "end" side, meaning right for left-right languages and left for right-to-left languages.
274-
- The `<amp-sidebar>` has default background color of white and is overridable in CSS.
275-
- Default width of `<amp-sidebar>` is `75%` of the viewport up to `360px`, on and `25%` up to `600px` for desktop experiences. Width can be overriden using the CSS `width` property, but has to be contained within these intervals.
276-
- A 'hamburger' style button that opens/closes the sidebar will appear on the story UI.
277-
278-
There are certain restrictions on what attributes and features are allowed in order to provide a consistent UI experience across the story platform. The following are allowed attributes and features of an `amp-sidebar` within an `amp-story`.
279-
280-
#### Allowed Attributes
281-
282-
- [layout](#layout)
283-
- [data-close-button-aria-label](#data)
284-
- [common attributes](#common)
285-
286-
_Example: Basic Sidebar in a Story_
287-
288-
The following example shows a simple `amp-sidebar` within an `amp-story`.
289-
290-
```html
291-
...
292-
<body>
293-
<amp-story standalone>
294-
<amp-sidebar id="sidebar1" layout="nodisplay">
295-
<ul>
296-
<li><a href="https://www.ampproject.org"> External Link </a></li>
297-
<li>Nav item 2</li>
298-
<li>Nav item 3</li>
299-
</ul>
300-
</amp-sidebar>
301-
<amp-story-page id="cover">
302-
<amp-story-grid-layer template="fill">
303-
<h1>Hello World</h1>
304-
<p>This is the cover page of this story.</p>
305-
</amp-story-grid-layer>
306-
</amp-story-page>
307-
...
308-
</body>
309-
```
310-
311-
[/filter]<!-- formats="stories" -->
312-
313262
## Attributes
314263

315264
##### side

extensions/amp-story/amp-story-analytics.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,6 @@ The `story-open` trigger is fired when opening a drawer or dialog inside a story
124124
- Page attachment (`<amp-story-page-attachment>`)
125125
- Share dialog (`<amp-story-share-menu>`)
126126
- Info dialog (`<amp-story-info-dialog>`)
127-
- Sidebar (`<amp-sidebar>`)
128127

129128
To use it, specify the trigger on your `"triggers"` property of your analytics configuration, accompanied by the `"tagName"` of the element you want to track.
130129

extensions/amp-story/amp-story.md

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -493,38 +493,11 @@ Example:
493493
</a>
494494
```
495495

496-
#### Integration with sidebar for stories
497-
498-
`amp-story` supports the use of `amp-sidebar` with a few limitations and caveats. See the [Sidebar for Stories documentation](https://amp.dev/documentation/components/amp-sidebar?format=websites#sidebar-for-stories) for more details.
499-
500-
By using branching and `amp-sidebar`, you can create stories that have a table of contents. To do this, make use of URL fragment parameter.
501-
502-
The following example demonstrates a table of contents inside of an `amp-sidebar`. The table of contents has a link to a specific story page, and and out-link to a different website.
503-
504-
```html
505-
<amp-story id="story" standalone>
506-
<amp-sidebar id="sidebar1" layout="nodisplay">
507-
<ul>
508-
<li><a href="#page=bacon-page"> Bacon page </a></li>
509-
<li><a href="https://www.amp.dev"> External Link </a></li>
510-
</ul>
511-
</amp-sidebar>
512-
513-
<amp-story-page id="bacon-page">
514-
<amp-story-grid-layer>
515-
<p>Bacon, of course!</p>
516-
</amp-story-grid-layer>
517-
</amp-story-page>
518-
...
519-
</amp-story>
520-
```
521-
522496
#### Other components usable in AMP stories
523497

524498
The following are other components usable in AMP stories that require some story-specific caveats.
525499

526500
- [amp-consent](https://amp.dev/documentation/components/amp-consent#prompt-ui-for-stories)
527-
- [amp-sidebar](https://amp.dev/documentation/components/amp-sidebar#sidebar-for-stories)
528501
- [amp-twitter](https://amp.dev/documentation/components/amp-twitter)
529502

530503
For more generally usable components see the [list of allowed children](https://amp.dev/documentation/components/amp-story#children).
@@ -847,7 +820,7 @@ With branching, AMP Stories now supports URLs in the form of:
847820
https://www.mydomain.com/good-story/#page=<page-id>
848821
```
849822

850-
where `page-id` refers to the unique id of an `amp-story-page`. You can also use the fragment parameter and the `page-id` value like an anchor link in some use cases. See [Integration with Sidebar for Stories](#integration-with-sidebar-for-stories) for an example.
823+
where `page-id` refers to the unique id of an `amp-story-page`. You can also use the fragment parameter and the `page-id` value like an anchor link in some use cases.
851824

852825
## Localization
853826

0 commit comments

Comments
 (0)