Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ To run the project locally:

1. Optionally create a `.env.local` file in the root of the project to override the values set in `.env`

1. `npm run start` - This will serve an index.html file located in `public` dir which includes the project
1. `npm run start` - This will serve an index.html file located at the root which includes the project

1. The served project will automatically open in your default browser.

Expand Down
86 changes: 86 additions & 0 deletions calendar-booking-cancel-form.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
<html>
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=5"
/>

<!-- Must include Material Icons which are used by Form -->
<link
rel="stylesheet"
href="https://fonts.googleapis.com/icon?family=Material+Icons"
/>

<script type="module" src="./src/dev.tsx"></script>
<script
charset="utf-8"
type="text/javascript"
src="./public/configuration.js"
></script>
<script>
window.addEventListener('load', function (event) {
OneBlinkForms.renderCalendarBookingCancelForm({
selector: '#oneblink-calendar-booking-cancel-form',
formsAppId: window.__DEVELOPMENT_FORMS_APP_ID__,
})
})
</script>

<style>
html,
body {
margin: 0;
padding: 0;
}

/* Styles to center form */
#oneblink-calendar-booking-cancel-form {
padding: 30px;
}

nylas-scheduling {
margin: auto;
}

/* Styles to prove @oneblink/apps-react styles are contained */
.button {
background: blue;
color: white;
}

.footer,
.hero {
background: lightblue;
height: 300px;
display: flex;
align-items: center;
padding: 50px;
}

.hero {
margin-bottom: 50px;
}

.footer {
margin-top: 50px;
}
</style>
</head>

<body>
<div class="hero">
<div>
<h1>Best Website Ever!!!</h1>
<h3>Well, it would be if more people thought it was good...</h3>
<button class="button">My .button Class</button>
</div>
</div>
<div id="oneblink-calendar-booking-cancel-form"></div>
<div class="footer">
<div>
<h3>OK, I lied, it's not as good as I want it to be...</h3>
</div>
</div>
</body>
</html>
89 changes: 89 additions & 0 deletions calendar-booking-form.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
<html>
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=5"
/>

<!-- Must include Material Icons which are used by Form -->
<link
rel="stylesheet"
href="https://fonts.googleapis.com/icon?family=Material+Icons"
/>

<script type="module" src="./src/dev.tsx"></script>
<script
charset="utf-8"
type="text/javascript"
src="./public/configuration.js"
></script>
<script>
window.addEventListener('load', function (event) {
OneBlinkForms.renderCalendarBookingForm({
selector: '#oneblink-calendar-booking-form',
formsAppId: window.__DEVELOPMENT_FORMS_APP_ID__,
doneRedirectUrl:
window.__DEVELOPMENT_SUBMISSION_REDIRECT_URL__ ||
'https://google.com.au',
})
})
</script>

<style>
html,
body {
margin: 0;
padding: 0;
}

/* Styles to center form */
#oneblink-calendar-booking-form {
padding: 30px;
}

nylas-scheduling {
margin: auto;
}

/* Styles to prove @oneblink/apps-react styles are contained */
.button {
background: blue;
color: white;
}

.footer,
.hero {
background: lightblue;
height: 300px;
display: flex;
align-items: center;
padding: 50px;
}

.hero {
margin-bottom: 50px;
}

.footer {
margin-top: 50px;
}
</style>
</head>

<body>
<div class="hero">
<div>
<h1>Best Website Ever!!!</h1>
<h3>Well, it would be if more people thought it was good...</h3>
<button class="button">My .button Class</button>
</div>
</div>
<div id="oneblink-calendar-booking-form"></div>
<div class="footer">
<div>
<h3>OK, I lied, it's not as good as I want it to be...</h3>
</div>
</div>
</body>
</html>
86 changes: 86 additions & 0 deletions calendar-booking-reschedule-form.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
<html>
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=5"
/>

<!-- Must include Material Icons which are used by Form -->
<link
rel="stylesheet"
href="https://fonts.googleapis.com/icon?family=Material+Icons"
/>

<script type="module" src="./src/dev.tsx"></script>
<script
charset="utf-8"
type="text/javascript"
src="./public/configuration.js"
></script>
<script>
window.addEventListener('load', function (event) {
OneBlinkForms.renderCalendarBookingRescheduleForm({
selector: '#oneblink-calendar-booking-reschedule-form',
formsAppId: window.__DEVELOPMENT_FORMS_APP_ID__,
})
})
</script>

<style>
html,
body {
margin: 0;
padding: 0;
}

/* Styles to center form */
#oneblink-calendar-booking-reschedule-form {
padding: 30px;
}

nylas-scheduling {
margin: auto;
}

/* Styles to prove @oneblink/apps-react styles are contained */
.button {
background: blue;
color: white;
}

.footer,
.hero {
background: lightblue;
height: 300px;
display: flex;
align-items: center;
padding: 50px;
}

.hero {
margin-bottom: 50px;
}

.footer {
margin-top: 50px;
}
</style>
</head>

<body>
<div class="hero">
<div>
<h1>Best Website Ever!!!</h1>
<h3>Well, it would be if more people thought it was good...</h3>
<button class="button">My .button Class</button>
</div>
</div>
<div id="oneblink-calendar-booking-reschedule-form"></div>
<div class="footer">
<div>
<h3>OK, I lied, it's not as good as I want it to be...</h3>
</div>
</div>
</body>
</html>
112 changes: 112 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
<html>
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=5"
/>

<!-- Must include Material Icons which are used by Form -->
<link
rel="stylesheet"
href="https://fonts.googleapis.com/icon?family=Material+Icons"
/>

<script charset="utf-8" type="module" src="./src/dev.tsx"></script>
<script
charset="utf-8"
type="text/javascript"
src="./public/configuration.js"
></script>
<script>
if (typeof window.__DEVELOPMENT_FORM_ID__ !== 'number') {
throw new Error(
'"window.__DEVELOPMENT_FORM_ID__" must be set to run locally. See CONTRIBUTING.md for more details',
)
}
if (typeof window.__DEVELOPMENT_FORMS_APP_ID__ !== 'number') {
throw new Error(
'"window.__DEVELOPMENT_FORMS_APP_ID__" must be set to run locally. See CONTRIBUTING.md for more details',
)
}
window.addEventListener('load', function (event) {
OneBlinkForms.render({
formId: window.__DEVELOPMENT_FORM_ID__,
formsAppId: window.__DEVELOPMENT_FORMS_APP_ID__,
selector: '#form',
submissionRedirectUrl:
window.__DEVELOPMENT_SUBMISSION_REDIRECT_URL__ ||
'https://google.com.au',
cancelRedirectUrl:
window.__DEVELOPMENT_CANCEL_REDIRECT_URL__ ||
'https://google.com.au',
paymentReceiptUrl:
window.__DEVELOPMENT_PAYMENT_RECEIPT_URL__ ||
`${window.location.origin}/payment-receipt.html`,
paymentFormUrl:
window.__DEVELOPMENT_PAYMENT_FORM_URL__ ||
`${window.location.origin}/payment-form.html`,
calendarBookingFormUrl: `${window.location.origin}/calendar-booking-form.html`,
calendarBookingRescheduleFormUrl: `${window.location.origin}/calendar-booking-reschedule-form.html`,
calendarBookingCancelFormUrl: `${window.location.origin}/calendar-booking-cancel-form.html`,
externalId: window.__DEVELOPMENT_EXTERNAL_ID__,
token: window.__DEVELOPMENT_TOKEN__,
})
})
</script>

<style>
html,
body {
margin: 0;
padding: 0;
}

/* Styles to center form */
#form {
padding: 30px;
max-width: 800px;
margin: auto;
}

/* Styles to prove @oneblink/apps-react styles are contained */
.button {
background: blue;
color: white;
}

.footer,
.hero {
background: lightblue;
height: 300px;
display: flex;
align-items: center;
padding: 50px;
}

.hero {
margin-bottom: 50px;
}

.footer {
margin-top: 50px;
}
</style>
</head>

<body>
<div class="hero">
<div>
<h1>Best Website Ever!!!</h1>
<h3>Well, it would be if more people thought it was good...</h3>
<button class="button">My .button Class</button>
</div>
</div>
<div id="form"></div>
<div class="footer">
<div>
<h3>OK, I lied, it's not as good as I want it to be...</h3>
</div>
</div>
</body>
</html>
Loading