station 0.0.113 → 0.0.120
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Dockerfile +9 -7
- data/Gemfile +1 -1
- data/Gemfile.lock +2 -2
- data/docs/How-To-Use.md +2 -0
- data/lib/nexmo_developer/.nvmrc +1 -1
- data/lib/nexmo_developer/.ruby-version +1 -1
- data/lib/nexmo_developer/Gemfile +11 -12
- data/lib/nexmo_developer/Gemfile.lock +178 -117
- data/lib/nexmo_developer/Runbook.md +4 -4
- data/lib/nexmo_developer/app/controllers/jobs_controller.rb +7 -7
- data/lib/nexmo_developer/app/controllers/static_controller.rb +2 -13
- data/lib/nexmo_developer/app/models/feedback/feedback.rb +2 -0
- data/lib/nexmo_developer/app/models/tutorial/file_loader.rb +11 -7
- data/lib/nexmo_developer/app/models/tutorial/task.rb +27 -1
- data/lib/nexmo_developer/app/presenters/head.rb +5 -1
- data/lib/nexmo_developer/app/presenters/improve_page_presenter.rb +1 -1
- data/lib/nexmo_developer/app/services/orbit_feedback_notifier.rb +50 -0
- data/lib/nexmo_developer/app/services/translator/files_list_coordinator.rb +1 -1
- data/lib/nexmo_developer/app/views/contribute/guides/landing-pages.md +0 -10
- data/lib/nexmo_developer/app/views/contribute/guides/markdown-guide.md +3 -41
- data/lib/nexmo_developer/app/views/contribute/guides/platform.md +0 -1
- data/lib/nexmo_developer/app/views/layouts/documentation.html.erb +6 -0
- data/lib/nexmo_developer/app/views/layouts/partials/_sidenav_subitem.html.erb +3 -0
- data/lib/nexmo_developer/app/webpacker/javascript/components/jwt_generator/JwtGenerator.vue +1 -1
- data/lib/nexmo_developer/app/webpacker/javascript/sidenav/index.js +17 -0
- data/lib/nexmo_developer/app/webpacker/packs/application.js +1 -5
- data/lib/nexmo_developer/app/webpacker/stylesheets/custom/_core.scss +9 -3
- data/lib/nexmo_developer/app/webpacker/stylesheets/layout/_header.scss +3 -1
- data/lib/nexmo_developer/app/webpacker/stylesheets/objects/_navigation.scss +21 -2
- data/lib/nexmo_developer/config/routes.rb +0 -2
- data/lib/nexmo_developer/lib/tasks/cache.rake +1 -1
- data/lib/nexmo_developer/lib/tasks/careers.rake +1 -1
- data/lib/nexmo_developer/lib/tasks/ci.rake +30 -8
- data/lib/nexmo_developer/lib/tasks/diff.rake +5 -5
- data/lib/nexmo_developer/lib/tasks/documentation.rake +1 -1
- data/lib/nexmo_developer/lib/tasks/generate_search_terms.rake +2 -2
- data/lib/nexmo_developer/lib/tasks/links.rake +6 -6
- data/lib/nexmo_developer/lib/tasks/smartling.rake +1 -1
- data/lib/nexmo_developer/version.rb +1 -1
- data/package.json +33 -33
- data/station.gemspec +13 -13
- data/yarn.lock +1186 -2909
- metadata +68 -75
- data/lib/nexmo_developer/.dockerignore +0 -1
- data/lib/nexmo_developer/Dockerfile +0 -28
- data/lib/nexmo_developer/app/screenshots/webhook-url-for-delivery-receipt.js +0 -44
- data/lib/nexmo_developer/app/screenshots/webhook-url-for-inbound-message.js +0 -44
- data/lib/nexmo_developer/app/views/static/default_landing/partials/_submit_your_idea_form.html.erb +0 -58
- data/lib/nexmo_developer/app/webpacker/javascript/spotlight/index.js +0 -12
- data/lib/nexmo_developer/docker-compose.yml +0 -43
- data/lib/nexmo_developer/lib/tasks/screenshots.rake +0 -11
@@ -1,44 +0,0 @@
|
|
1
|
-
const puppeteer = require('puppeteer')
|
2
|
-
const fs = require('fs')
|
3
|
-
const sha1File = require('sha1-file')
|
4
|
-
require('dotenv').config()
|
5
|
-
|
6
|
-
if (!fs.existsSync('./public/assets/screenshots')){
|
7
|
-
fs.mkdirSync('./public/assets/screenshots')
|
8
|
-
}
|
9
|
-
|
10
|
-
(async () => {
|
11
|
-
const browser = await puppeteer.launch()
|
12
|
-
const page = await browser.newPage()
|
13
|
-
await page.setViewport({ width: 800, height: 500 })
|
14
|
-
await page.goto('https://dashboard.nexmo.com/sign-in')
|
15
|
-
|
16
|
-
await page.waitForSelector('input[name=username]')
|
17
|
-
await page.type('input[name=username]', process.env.NEXMO_USERNAME)
|
18
|
-
await page.type('input[name=password]', process.env.NEXMO_PASSWORD)
|
19
|
-
await page.click('#btn_login')
|
20
|
-
|
21
|
-
await page.waitForSelector('#nav-expander')
|
22
|
-
await page.goto('https://dashboard.nexmo.com/settings')
|
23
|
-
|
24
|
-
await page.waitForSelector('#nav-expander')
|
25
|
-
await page.click('#httpBaseUrlForMoPost')
|
26
|
-
|
27
|
-
await page.addStyleTag({
|
28
|
-
content: `
|
29
|
-
#sysId, #password, #signatureSecret {
|
30
|
-
filter: blur(5px)
|
31
|
-
}
|
32
|
-
`
|
33
|
-
})
|
34
|
-
|
35
|
-
await page.screenshot({ path: 'public/assets/screenshots/tmp.png' })
|
36
|
-
|
37
|
-
const sha = sha1File('public/assets/screenshots/tmp.png')
|
38
|
-
const newPath = `public/assets/screenshots/${sha}.png`
|
39
|
-
fs.renameSync('public/assets/screenshots/tmp.png', newPath)
|
40
|
-
|
41
|
-
await browser.close()
|
42
|
-
|
43
|
-
console.log(newPath)
|
44
|
-
})()
|
data/lib/nexmo_developer/app/views/static/default_landing/partials/_submit_your_idea_form.html.erb
DELETED
@@ -1,58 +0,0 @@
|
|
1
|
-
<h2 class="Vlt-title--icon" id="<%= local_assigns['header'].parameterize %>">
|
2
|
-
<svg class="Vlt-<%= local_assigns['icon']['color'] %>"><use xlink:href="<%= "/symbol/volta-icons.svg#Vlt-#{local_assigns['icon']['name']}" %>"></use></svg>
|
3
|
-
<%= local_assigns['header'].render_markdown(skip_paragraph_surround: true) %>
|
4
|
-
</h2>
|
5
|
-
|
6
|
-
<%= form_tag('/spotlight', remote: true, id: 'spotlight-form') do %>
|
7
|
-
<div class="Vlt-form__element">
|
8
|
-
<%= label_tag 'name', 'Your Name', class: 'Vlt-label' %>
|
9
|
-
<div class="Vlt-input">
|
10
|
-
<%= text_field_tag 'name', nil, required: true %>
|
11
|
-
</div>
|
12
|
-
</div>
|
13
|
-
|
14
|
-
<div class="Vlt-form__element">
|
15
|
-
<%= label_tag 'email_address', 'Your Email Address', class: 'Vlt-label' %>
|
16
|
-
<div class="Vlt-input">
|
17
|
-
<%= email_field_tag 'email_address', nil, required: true %>
|
18
|
-
</div>
|
19
|
-
</div>
|
20
|
-
|
21
|
-
<div class="Vlt-form__element">
|
22
|
-
<%= label_tag 'background', 'Please write a little about your background and why you want to write for Vonage', class: 'Vlt-label' %>
|
23
|
-
<div class="Vlt-textarea">
|
24
|
-
<%= text_area_tag 'background', nil, required: true, rows: 4, cols: 50 %>
|
25
|
-
</div>
|
26
|
-
</div>
|
27
|
-
|
28
|
-
<div class="Vlt-form__element">
|
29
|
-
<%= label_tag 'outline', 'The outline of your blog post idea', class: 'Vlt-label' %>
|
30
|
-
<div class="Vlt-textarea">
|
31
|
-
<%= text_area_tag 'outline', nil, required: true, rows: 4, cols: 50 %>
|
32
|
-
</div>
|
33
|
-
</div>
|
34
|
-
|
35
|
-
<div class="Vlt-form__element">
|
36
|
-
<%= label_tag 'previous_content', 'Please provide link to something you have written previously', class: 'Vlt-label' %>
|
37
|
-
<div class="Vlt-input">
|
38
|
-
<%= url_field_tag 'previous_content', nil %>
|
39
|
-
</div>
|
40
|
-
</div>
|
41
|
-
|
42
|
-
<small class="Vlt-form__element__hint">
|
43
|
-
By submitting your ideas to Vonage Developer Spotlight you accept our <a href='https://www.vonage.com/legal/privacy-policy/'>privacy policy</a>, which sets out how we use your data and the rights you have in respect of your data.
|
44
|
-
</small>
|
45
|
-
<%= submit_tag 'Submit', class: 'Vlt-btn Vlt-btn--secondary Vlt-btn--app' %>
|
46
|
-
<% end %>
|
47
|
-
<div id='success' class="Vlt-callout Vlt-callout--good Vlt-flash Vlt-flash--small ">
|
48
|
-
<i></i>
|
49
|
-
<div class="Vlt-callout__content">
|
50
|
-
<p>Thanks for your submission, we will review it and get in contact with you shortly</p>
|
51
|
-
</div>
|
52
|
-
</div>
|
53
|
-
<div id='error' class="Vlt-callout Vlt-callout--critical Vlt-flash Vlt-flash--small ">
|
54
|
-
<i></i>
|
55
|
-
<div class="Vlt-callout__content">
|
56
|
-
<p>Something went wrong with your submission. Please try again. If the error persists then please email your submission to deved@vonage.com</p>
|
57
|
-
</div>
|
58
|
-
</div>
|
@@ -1,12 +0,0 @@
|
|
1
|
-
import Volta from "../volta/volta.js"
|
2
|
-
|
3
|
-
export default () => {
|
4
|
-
$(document).ready(function() {
|
5
|
-
$(document).on('ajax:success', '#spotlight-form', function(event, response) {
|
6
|
-
Volta.flash.show('success');
|
7
|
-
event.target.reset();
|
8
|
-
}).on('ajax:error', '#spotlight-form', function(event) {
|
9
|
-
Volta.flash.show('error');
|
10
|
-
});
|
11
|
-
});
|
12
|
-
}
|
@@ -1,43 +0,0 @@
|
|
1
|
-
version: '3'
|
2
|
-
services:
|
3
|
-
db:
|
4
|
-
image: postgres
|
5
|
-
environment:
|
6
|
-
- POSTGRES_HOST_AUTH_METHOD=trust
|
7
|
-
web:
|
8
|
-
image: nexmodeveloper_app
|
9
|
-
build: .
|
10
|
-
command: bundle exec rails s -p 3000 -b '0.0.0.0'
|
11
|
-
volumes:
|
12
|
-
- .:/app
|
13
|
-
- /app/node_modules
|
14
|
-
ports:
|
15
|
-
- "3000:3000"
|
16
|
-
depends_on:
|
17
|
-
- clean
|
18
|
-
- update
|
19
|
-
- db
|
20
|
-
environment:
|
21
|
-
- OAS_PATH=_open_api/api_specs/definitions
|
22
|
-
- DOCS_BASE_PATH=.
|
23
|
-
- POSTGRES_HOST=db
|
24
|
-
- POSTGRES_USERNAME=postgres
|
25
|
-
- RAILS_ENV=development
|
26
|
-
- RACK_ENV=development
|
27
|
-
clean:
|
28
|
-
image: nexmodeveloper_app
|
29
|
-
build: .
|
30
|
-
command: bash -c "rm -Rf public/packs && rm -f /app/tmp/pids/server.pid"
|
31
|
-
volumes:
|
32
|
-
- .:/app
|
33
|
-
update:
|
34
|
-
image: nexmodeveloper_app
|
35
|
-
build: .
|
36
|
-
command: bash -c "rake db:setup"
|
37
|
-
volumes:
|
38
|
-
- .:/app
|
39
|
-
depends_on:
|
40
|
-
- db
|
41
|
-
environment:
|
42
|
-
- POSTGRES_HOST=db
|
43
|
-
- POSTGRES_USERNAME=postgres
|