File tree Expand file tree Collapse file tree 2 files changed +8
-6
lines changed
apps/components_guide_web/lib/components_guide_web/templates/web_standards Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change 1- # URL
1+ # Anatomy of a URL
22
3- ## Anatomy of a URL
3+ ## Change the parts of a URL
44
55<live-render >
66ComponentsGuideWeb.WebStandards.Live.URL
77</live-render >
88
9+ ----
10+
911## JavaScript’s ` URL `
1012
1113``` js
Original file line number Diff line number Diff line change @@ -84,7 +84,7 @@ defmodule ComponentsGuideWeb.WebStandards.Live.URL do
8484 <form phx-change=change>
8585
8686 <pre class="p-4 my-2" style="color: #d6deeb;">
87- <code><span class="text-green -400"><%= State.to_url(@state).scheme %></span>://<span class="text-yellow -400"><%= State.to_url(@state).host %></span><span class="text-orange-400"><%= State.to_url(@state).path %></span><span class="text-indigo -400"><%= @state |> State.read(:query) %></span></code>
87+ <code><span class="text-yellow -400"><%= State.to_url(@state).scheme %></span>://<span class="text-green -400"><%= State.to_url(@state).host %></span><span class="text-orange-400"><%= State.to_url(@state).path %></span><span class="text-blue -400"><%= @state |> State.read(:query) %></span></code>
8888 </pre>
8989
9090 <div class="flex flex-col space-y-4">
@@ -105,15 +105,15 @@ defmodule ComponentsGuideWeb.WebStandards.Live.URL do
105105 </label>
106106
107107 <label>
108- <span class="font-bold text-orange -400 mr-2">Query</span>
108+ <span class="font-bold text-blue -400 mr-2">Query</span>
109109 <button type=button phx-click=add-query class="px-2 bg-white text-black rounded">Add query</button>
110110 <button type=button phx-click=clear-query class="px-2 bg-white text-black rounded">Clear query</button>
111111
112112 <div class="space-y-2 mt-2">
113113 <%= for {key, value} <- State.get_query_vars(@state) do %>
114114 <div>
115- <input name=query-keys[] type=text value="<%= key %>" class="text-black text-indigo -900 bg-indigo -100 px-2">
116- <input name=query-values[] type=text value="<%= value %>" class="text-black text-indigo -900 bg-indigo -100 px-2">
115+ <input name=query-keys[] type=text value="<%= key %>" class="text-black text-blue -900 bg-blue -100 px-2">
116+ <input name=query-values[] type=text value="<%= value %>" class="text-black text-blue -900 bg-blue -100 px-2">
117117 </div>
118118 <% end %>
119119 </div>
You can’t perform that action at this time.
0 commit comments