Skip to content

Commit

Permalink
Add field to include placements on print. Add pointer cursor to selec…
Browse files Browse the repository at this point in the history
…t dropdowns.
  • Loading branch information
andrewtoups committed Aug 26, 2021
1 parent 33b5702 commit 6ae2087
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
9 changes: 9 additions & 0 deletions scripts/components/relics/relics.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,15 @@
<input data-bind="value: email" type="email" placeholder="Email Address" id="email" autocomplete="email">
</div>

<div class="field select" data-bind="css: {placeholder: !includePlacements()}">
<label for="placements" class="required">Include placements</label>
<select data-bind="value: includePlacements" id="placements">
<option value="" disabled='disabled' selected>Include placements on print?</option>
<option value="true">Yes</option>
<option value="false">No</option>
</select>
</div>

<fieldset data-bind="css: {validating: validating, verified: verified() || verificationFailed()}">
<legend>Recipient address</legend>
<i class="loader" data-bind="visible: validating"></i>
Expand Down
2 changes: 2 additions & 0 deletions scripts/components/relics/relics.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ define(['ko', 'paypal', 'api'], (ko, paypal, api) => {

self.name = ko.observable("");
self.email = ko.observable("");
self.includePlacements = ko.observable();

self.line1 = ko.observable("");
self.line2 = ko.observable("");
Expand Down Expand Up @@ -148,6 +149,7 @@ define(['ko', 'paypal', 'api'], (ko, paypal, api) => {
let body = {
orderName: self.name(),
orderEmail: self.email(),
includePlacements: self.includePlacements(),
address: self.addressStr(self.address()),
correctionDenied: self.correctionDenied(),
validatedAddress: self.addressStr(self.validatedAddress()),
Expand Down
3 changes: 2 additions & 1 deletion styles/components/_relics.scss
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,8 @@ button.buy {
select {
border-bottom: none;
position: relative;
left: -1.5px;
left: -1.5px;
cursor: pointer;
}
&.placeholder select { opacity: .375; }
}
Expand Down

0 comments on commit 6ae2087

Please sign in to comment.