Skip to content

Commit a60d3d6

Browse files
committed
Update view templates
This changes edits the styling of the view slightly with bootstrap and removes the default Phoenix styles. We also change the TOML documentation metadata structure slightly so that sliding information is included _within_ a synth/fx's data, not along-side it as an adjacent key/value.
1 parent 71a22c5 commit a60d3d6

File tree

5 files changed

+5
-120
lines changed

5 files changed

+5
-120
lines changed

etc/doc/templates/slides.toml.erb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[sliding]
1+
[<%= key %>.sliding]
22
slide_label = "<%= t_('Slide Options') %>"
33
slide_description = '''
44
<%=
@@ -17,7 +17,7 @@ slide_opts = {
1717
}
1818
-%>
1919
<% slide_opts.each do |name, attributes| %>
20-
[[sliding.slide_opts]]
20+
[[<%= key %>.sliding.slide_opts]]
2121
name = "<%= name %>"
2222
default = "<%= attributes[:default] %>"
2323
doc = '''

etc/docs/assets/css/app.scss

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
/* This file is for your main application css. */
2-
@import "./phoenix.css";
32

43
/* LiveView specific classes for your customizations */
54
.phx-no-feedback.invalid-feedback,

etc/docs/assets/css/phoenix.css

Lines changed: 0 additions & 101 deletions
This file was deleted.

etc/docs/lib/docs_web/templates/layout/live.html.leex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<main role="main" class="container">
1+
<main role="main" class="container-fluid">
22
<p class="alert alert-info" role="alert"
33
phx-click="lv:clear-flash"
44
phx-value-key="info"><%= live_flash(@flash, :info) %></p>

etc/docs/lib/docs_web/templates/layout/root.html.leex

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,24 +7,11 @@
77
<%= csrf_meta_tag() %>
88
<%= live_title_tag assigns[:page_title] || "Docs", suffix: " · Phoenix Framework" %>
99
<link phx-track-static rel="stylesheet" href="<%= Routes.static_path(@conn, "/css/app.css") %>"/>
10+
<link phx-track-static rel="stylesheet" href="<%= Routes.static_path(@conn, "/css/bootstrap.min.css") %>"/>
1011
<script defer phx-track-static type="text/javascript" src="<%= Routes.static_path(@conn, "/js/app.js") %>"></script>
1112
</head>
1213
<body>
13-
<header>
14-
<section class="container">
15-
<nav role="navigation">
16-
<ul>
17-
<li><a href="https://hexdocs.pm/phoenix/overview.html">Get Started</a></li>
18-
<%= if function_exported?(Routes, :live_dashboard_path, 2) do %>
19-
<li><%= link "LiveDashboard", to: Routes.live_dashboard_path(@conn, :home) %></li>
20-
<% end %>
21-
</ul>
22-
</nav>
23-
<a href="https://phoenixframework.org/" class="phx-logo">
24-
<img src="<%= Routes.static_path(@conn, "/images/phoenix.png") %>" alt="Phoenix Framework Logo"/>
25-
</a>
26-
</section>
27-
</header>
2814
<%= @inner_content %>
15+
<script defer phx-track-static type="text/javascript" src="<%= Routes.static_path(@conn, "/js/bootstrap.bundle.min.js") %>"></script>
2916
</body>
3017
</html>

0 commit comments

Comments
 (0)