station 0.0.107 → 0.0.112

Sign up to get free protection for your applications and to get access to all the features.
Files changed (106) hide show
  1. checksums.yaml +4 -4
  2. data/bin/nexmo-developer +7 -0
  3. data/lib/nexmo_developer/Gemfile +15 -25
  4. data/lib/nexmo_developer/Gemfile.lock +131 -143
  5. data/lib/nexmo_developer/app/assets/config/manifest.js +1 -4
  6. data/lib/nexmo_developer/app/assets/javascripts/application.js +2 -7
  7. data/lib/nexmo_developer/app/assets/stylesheets/application.css +1 -1
  8. data/lib/nexmo_developer/app/controllers/dashboard_controller.rb +0 -5
  9. data/lib/nexmo_developer/app/controllers/static_controller.rb +3 -11
  10. data/lib/nexmo_developer/app/models/tutorial.rb +10 -12
  11. data/lib/nexmo_developer/app/models/tutorial/prerequisite.rb +3 -1
  12. data/lib/nexmo_developer/app/models/tutorial/task.rb +24 -11
  13. data/lib/nexmo_developer/app/presenters/improve_page_presenter.rb +7 -6
  14. data/lib/nexmo_developer/app/services/translator/files_list_coordinator.rb +90 -0
  15. data/lib/nexmo_developer/app/services/translator/smartling/api/download_file.rb +6 -1
  16. data/lib/nexmo_developer/app/services/translator/smartling/api/file_status.rb +7 -1
  17. data/lib/nexmo_developer/app/services/translator/utils.rb +1 -1
  18. data/lib/nexmo_developer/app/views/admin/feedbacks/_steps.html.erb +1 -1
  19. data/lib/nexmo_developer/app/views/contribute/guides/markdown-guide.md +36 -2
  20. data/lib/nexmo_developer/app/views/dashboard/stats.html.erb +2 -2
  21. data/lib/nexmo_developer/app/views/layouts/partials/_head.html.erb +0 -5
  22. data/lib/nexmo_developer/app/views/static/_products.html.erb +14 -11
  23. data/lib/nexmo_developer/app/views/static/default_landing/partials/_join_slack.html.erb +1 -1
  24. data/lib/nexmo_developer/app/views/static/landing.html.erb +8 -8
  25. data/lib/nexmo_developer/app/views/static/{robots.txt.erb → robots.text.erb} +0 -0
  26. data/lib/nexmo_developer/app/webpacker/fonts/Lato-Black.woff +0 -0
  27. data/lib/nexmo_developer/app/webpacker/fonts/Lato-Black.woff2 +0 -0
  28. data/lib/nexmo_developer/app/webpacker/fonts/Lato-Regular.woff +0 -0
  29. data/lib/nexmo_developer/app/webpacker/fonts/Lato-Regular.woff2 +0 -0
  30. data/lib/nexmo_developer/app/webpacker/fonts/Lato-Semibold.woff +0 -0
  31. data/lib/nexmo_developer/app/webpacker/fonts/Lato-Semibold.woff2 +0 -0
  32. data/lib/nexmo_developer/app/webpacker/fonts/icomoon.eot +0 -0
  33. data/lib/nexmo_developer/app/webpacker/fonts/icomoon.json +1257 -0
  34. data/lib/nexmo_developer/app/webpacker/fonts/icomoon.svg +55 -0
  35. data/lib/nexmo_developer/app/webpacker/fonts/icomoon.ttf +0 -0
  36. data/lib/nexmo_developer/app/webpacker/fonts/icomoon.woff +0 -0
  37. data/lib/nexmo_developer/app/{assets → webpacker}/images/.keep +0 -0
  38. data/lib/nexmo_developer/app/{assets → webpacker}/images/logo@3x.png +0 -0
  39. data/lib/nexmo_developer/app/{assets → webpacker}/images/logo_vonage.png +0 -0
  40. data/lib/nexmo_developer/app/{assets → webpacker}/images/nexmo-developer-logo.svg +0 -0
  41. data/lib/nexmo_developer/app/{assets → webpacker}/images/nexmo-logo-collapsed.svg +0 -0
  42. data/lib/nexmo_developer/app/{assets → webpacker}/images/nexmo-vonage-white.svg +0 -0
  43. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/chatapp.jpg +0 -0
  44. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/chatapp_small.png +0 -0
  45. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/nexmo.jpg +0 -0
  46. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/numberinsight.jpg +0 -0
  47. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/numberinsight_small.png +0 -0
  48. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/sms.jpg +0 -0
  49. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/sms_small.png +0 -0
  50. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/verify.jpg +0 -0
  51. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/verify_small.png +0 -0
  52. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/voice.jpg +0 -0
  53. data/lib/nexmo_developer/app/{assets → webpacker}/images/posters/voice_small.png +0 -0
  54. data/lib/nexmo_developer/app/{assets → webpacker}/images/select-dropdown.png +0 -0
  55. data/lib/nexmo_developer/app/{assets → webpacker}/images/slack.svg +0 -0
  56. data/lib/nexmo_developer/app/{assets → webpacker}/images/themes/ea/topography.png +0 -0
  57. data/lib/nexmo_developer/app/webpacker/javascript/code_snippet_events/index.js +23 -85
  58. data/lib/nexmo_developer/app/webpacker/javascript/volta/volta.js +6 -2
  59. data/lib/nexmo_developer/app/webpacker/javascript/volta_tabbed_examples/index.js +23 -3
  60. data/lib/nexmo_developer/app/webpacker/packs/active_admin.js +5 -0
  61. data/lib/nexmo_developer/app/webpacker/packs/active_admin/print.scss +2 -0
  62. data/lib/nexmo_developer/app/webpacker/packs/application.js +12 -0
  63. data/lib/nexmo_developer/app/{assets → webpacker}/stylesheets/active_admin.scss +4 -4
  64. data/lib/nexmo_developer/app/webpacker/stylesheets/application.scss +0 -1
  65. data/lib/nexmo_developer/config/environments/development.rb +1 -1
  66. data/lib/nexmo_developer/config/initializers/active_admin.rb +3 -0
  67. data/lib/nexmo_developer/config/webpack/environment.js +10 -0
  68. data/lib/nexmo_developer/config/webpack/plugins/jquery.js +7 -0
  69. data/lib/nexmo_developer/lib/tasks/smartling.rake +7 -0
  70. data/lib/nexmo_developer/nexmo_developer.rb +3 -4
  71. data/lib/nexmo_developer/version.rb +1 -1
  72. data/package.json +23 -15
  73. data/station.gemspec +9 -13
  74. data/yarn.lock +1473 -1011
  75. metadata +200 -226
  76. data/lib/nexmo_developer/app/assets/javascripts/active_admin.js.coffee +0 -1
  77. data/lib/nexmo_developer/app/assets/javascripts/stats.js +0 -14
  78. data/lib/nexmo_developer/app/assets/regex/matching_chars.rb +0 -1
  79. data/lib/nexmo_developer/app/assets/regex/sequence_diagram_regex.rb +0 -1
  80. data/lib/nexmo_developer/app/assets/regex/stats_regex.rb +0 -1
  81. data/lib/nexmo_developer/app/assets/regex/webfont_regex.rb +0 -1
  82. data/lib/nexmo_developer/app/views/slack/join.html.erb +0 -25
  83. data/lib/nexmo_developer/app/views/static/_community.html.erb +0 -24
  84. data/lib/nexmo_developer/app/views/static/_dotnet.html.erb +0 -26
  85. data/lib/nexmo_developer/app/views/static/_slack.html.erb +0 -2
  86. data/lib/nexmo_developer/app/views/static/_xwithy.html.erb +0 -33
  87. data/lib/nexmo_developer/app/views/static/podcast.html.erb +0 -40
  88. data/lib/nexmo_developer/app/webpacker/stylesheets/objects/_building-block.scss +0 -32
  89. data/lib/nexmo_developer/vendor/assets/javascripts/jquery-scrolltofixed.js +0 -567
  90. data/lib/nexmo_developer/vendor/assets/javascripts/mermaid.js +0 -49
  91. data/lib/nexmo_developer/vendor/assets/javascripts/underscore.js +0 -5
  92. data/lib/nexmo_developer/vendor/assets/javascripts/volta/addons/jquery.tablesorter.js +0 -1031
  93. data/lib/nexmo_developer/vendor/assets/javascripts/volta/addons/prism.js +0 -22
  94. data/lib/nexmo_developer/vendor/assets/javascripts/volta/components/side-navigation/volta.menu.js +0 -377
  95. data/lib/nexmo_developer/vendor/assets/javascripts/volta/components/volta.accordion.js +0 -249
  96. data/lib/nexmo_developer/vendor/assets/javascripts/volta/components/volta.dropdown.js +0 -145
  97. data/lib/nexmo_developer/vendor/assets/javascripts/volta/components/volta.flash.js +0 -175
  98. data/lib/nexmo_developer/vendor/assets/javascripts/volta/components/volta.modal.js +0 -312
  99. data/lib/nexmo_developer/vendor/assets/javascripts/volta/components/volta.tab.js +0 -203
  100. data/lib/nexmo_developer/vendor/assets/javascripts/volta/components/volta.tooltip.js +0 -71
  101. data/lib/nexmo_developer/vendor/assets/javascripts/volta/popper.min.js +0 -5
  102. data/lib/nexmo_developer/vendor/assets/javascripts/volta/svgxuse.min.js +0 -12
  103. data/lib/nexmo_developer/vendor/assets/javascripts/volta/tooltip.min.js +0 -5
  104. data/lib/nexmo_developer/vendor/assets/javascripts/volta/volta.core.js +0 -238
  105. data/lib/nexmo_developer/vendor/assets/javascripts/volta/volta.js +0 -2141
  106. data/lib/nexmo_developer/vendor/assets/javascripts/volta/volta.min.js +0 -1
@@ -1,5 +1,2 @@
1
- //= link_tree ../images
2
- //= link_directory ../regex .rb
3
1
  //= link application.js
4
- //= link application.css
5
- //= link stats.js
2
+ //= link application.css
@@ -1,3 +1,4 @@
1
+
1
2
  // This is a manifest file that'll be compiled into application.js, which will include all the files
2
3
  // listed below.
3
4
  //
@@ -10,10 +11,4 @@
10
11
  // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11
12
  // about supported directives.
12
13
  //
13
- //= require jquery
14
- //= require jquery-scrolltofixed
15
- //= require clipboard
16
- //= require underscore
17
- //= require gmaps/google
18
- //= require javascripts/nexmo-oas-renderer
19
- //= require mermaid
14
+ //= require javascripts/nexmo-oas-renderer
@@ -1 +1 @@
1
- //= require stylesheets/nexmo-oas-renderer
1
+ //= require stylesheets/nexmo-oas-renderer
@@ -1,6 +1,5 @@
1
1
  class DashboardController < ApplicationController
2
2
  before_action :authenticate_admin!
3
- before_action :set_additional_scripts
4
3
 
5
4
  def stats
6
5
  @feedbacks = Feedback::Feedback.created_between(created_after, created_before)
@@ -104,10 +103,6 @@ class DashboardController < ApplicationController
104
103
 
105
104
  private
106
105
 
107
- def set_additional_scripts
108
- @additional_scripts = ['stats']
109
- end
110
-
111
106
  def ignore_languages
112
107
  return params[:ignore].split(',') if params[:ignore].present?
113
108
 
@@ -113,17 +113,9 @@ class StaticController < ApplicationController
113
113
  end
114
114
 
115
115
  def robots
116
- render 'robots.txt'
117
- end
118
-
119
- def podcast
120
- # Get URL and split the / to retrieve the landing page name
121
- yaml_name = request.fullpath.split('/')[1]
122
-
123
- # Load the YAML for that particular page
124
- @content = YAML.load_file("#{Rails.root}/config/landing_pages/#{yaml_name}.yml")
125
-
126
- render layout: 'landing'
116
+ respond_to do |format|
117
+ format.any { render plain: 'robots', layout: false, content_type: 'text/plain' }
118
+ end
127
119
  end
128
120
 
129
121
  def team
@@ -84,20 +84,18 @@ class Tutorial
84
84
  subtasks[current_task_index - 1]
85
85
  end
86
86
 
87
+ def tasks
88
+ @tasks ||= (yaml['tasks'] || []).map do |t|
89
+ Task.make_from(
90
+ name: t,
91
+ code_language: code_language,
92
+ current_step: current_step
93
+ )
94
+ end
95
+ end
96
+
87
97
  def subtasks
88
98
  @subtasks ||= begin
89
- tasks = []
90
-
91
- (yaml['tasks'] || []).map do |t|
92
- tasks.push(
93
- Task.make_from(
94
- name: t,
95
- code_language: code_language,
96
- current_step: current_step
97
- )
98
- )
99
- end
100
-
101
99
  tasks.unshift(prerequisite_task)
102
100
  tasks.unshift(introduction_task)
103
101
  tasks.push(conclusion_task)
@@ -1,5 +1,7 @@
1
1
  class Tutorial::Prerequisite
2
- delegate :content, :yaml, to: :@file_loader
2
+ attr_reader :name
3
+
4
+ delegate :content, :yaml, :path, to: :@file_loader
3
5
 
4
6
  def initialize(current_step:, code_language:, name:)
5
7
  @current_step = current_step
@@ -1,11 +1,24 @@
1
1
  class Tutorial::Task
2
- attr_reader :name, :title, :description, :current_step
2
+ attr_reader :name, :code_language, :current_step
3
3
 
4
- def initialize(name:, title:, description:, current_step:)
4
+ delegate :yaml, :path, to: :@file_loader
5
+
6
+ def initialize(name:, current_step:, code_language: nil, title: nil, description: nil)
5
7
  @name = name
6
8
  @title = title
7
9
  @description = description
10
+ @code_language = code_language
8
11
  @current_step = current_step
12
+ @file_loader = load_file!
13
+ end
14
+
15
+ def load_file!
16
+ Tutorial::FileLoader.new(
17
+ root: Tutorial.task_content_path,
18
+ doc_name: @name,
19
+ code_language: @code_language,
20
+ format: 'md'
21
+ )
9
22
  end
10
23
 
11
24
  def active?
@@ -13,17 +26,9 @@ class Tutorial::Task
13
26
  end
14
27
 
15
28
  def self.make_from(name:, code_language:, current_step:)
16
- file_loader = Tutorial::FileLoader.new(
17
- root: Tutorial.task_content_path,
18
- doc_name: name,
19
- code_language: code_language,
20
- format: 'md'
21
- )
22
-
23
29
  new(
24
30
  name: name,
25
- title: file_loader.yaml['title'],
26
- description: file_loader.yaml['description'],
31
+ code_language: code_language,
27
32
  current_step: current_step
28
33
  )
29
34
  end
@@ -42,4 +47,12 @@ class Tutorial::Task
42
47
  def hash
43
48
  name.hash ^ title.hash ^ description.hash ^ current_step.hash
44
49
  end
50
+
51
+ def title
52
+ @title || yaml['title']
53
+ end
54
+
55
+ def description
56
+ @description || yaml['description']
57
+ end
45
58
  end
@@ -7,13 +7,14 @@ class ImprovePagePresenter
7
7
  @github_url ||= "https://github.com/#{docs_repo}/blob/#{ENV.fetch('branch', 'master')}/#{path_to_url}"
8
8
  end
9
9
 
10
- private
11
-
12
- def path_to_url
13
- @document_path&.gsub("#{Rails.configuration.docs_base_path}/", '')
10
+ def docs_repo
11
+ @docs_repo ||= begin
12
+ path_to_url.start_with?('lib/nexmo_developer/app/') ? 'nexmo/station' : YAML.safe_load(File.open("#{Rails.configuration.docs_base_path}/config/business_info.yml"))['docs_repo']
13
+ end
14
14
  end
15
15
 
16
- def docs_repo
17
- @docs_repo ||= YAML.safe_load(File.open("#{Rails.configuration.docs_base_path}/config/business_info.yml"))['docs_repo']
16
+ def path_to_url
17
+ @document_path&.gsub!("#{Rails.configuration.docs_base_path}/", '')
18
+ @document_path.start_with?('app/') ? @document_path.prepend('lib/nexmo_developer/') : @document_path
18
19
  end
19
20
  end
@@ -0,0 +1,90 @@
1
+ module Translator
2
+ class FilesListCoordinator
3
+ def self.call(attrs = {})
4
+ new(attrs).call
5
+ end
6
+
7
+ def initialize(days:)
8
+ @days = days
9
+ end
10
+
11
+ def call
12
+ process_files(files)
13
+ end
14
+
15
+ def files
16
+ @files ||= `(git fetch origin master:master) && (git log --since="#{@days} days" --name-only --oneline --diff-filter=ACM --pretty=format: master #{Rails.configuration.docs_base_path}/_documentation/en #{Rails.configuration.docs_base_path}/_tutorials/en #{Rails.configuration.docs_base_path}/_use_cases/en) | uniq | awk 'NF'`.split("\n")
17
+ end
18
+
19
+ def process_files(files)
20
+ files.each_with_object([]) do |file, list|
21
+ if file.include?('_documentation')
22
+ list << file if translatable_doc_file?(file)
23
+ elsif file.include?('_use_cases')
24
+ list << file if translatable_use_case_file?(file)
25
+ elsif file.include?('_tutorials')
26
+ list << file if translatable_tutorial_file?(file)
27
+ else
28
+ raise ArgumentError, "The following file did not match documentation, use cases or tutorials: #{file}"
29
+ end
30
+ end
31
+ end
32
+
33
+ def translatable_doc_file?(file)
34
+ return nil unless File.exist?("#{Rails.configuration.docs_base_path}/#{file}")
35
+
36
+ allowed_products.any? do |product|
37
+ product['path'].include?(file.split('/')[2])
38
+ end
39
+ end
40
+
41
+ def translatable_use_case_file?(file)
42
+ return nil unless File.exist?("#{Rails.configuration.docs_base_path}/#{file}")
43
+
44
+ allowed_products.any? do |product|
45
+ use_case_product(file).include?(product['path'])
46
+ end
47
+ end
48
+
49
+ def use_case_product(file)
50
+ @use_case_product = YAML.safe_load(File.read("#{Rails.configuration.docs_base_path}/#{file}"))['products']
51
+
52
+ @use_case_product
53
+ end
54
+
55
+ def translatable_tutorial_file?(file)
56
+ return nil unless File.exist?("#{Rails.configuration.docs_base_path}/#{file}")
57
+
58
+ allowed_tutorial_files.any? do |tutorial|
59
+ tutorial.include?(file)
60
+ end
61
+ end
62
+
63
+ def allowed_products
64
+ @allowed_products ||= YAML.safe_load(File.read("#{Rails.configuration.docs_base_path}/config/products.yml"))['products'].select { |product| product['translate'] == true }
65
+ end
66
+
67
+ def allowed_tutorial_files
68
+ file_names = []
69
+ tutorials_list = []
70
+
71
+ TutorialList.all.each do |item|
72
+ allowed_products.each do |product|
73
+ tutorials_list << item if item.products.to_s.include?(product['path'])
74
+ end
75
+ end
76
+
77
+ tutorials_list.each do |item|
78
+ item.tutorial.prerequisites&.each do |prereq|
79
+ file_names << prereq.path
80
+ end
81
+
82
+ item.tutorial.tasks&.each do |task|
83
+ file_names << task.path
84
+ end
85
+ end
86
+
87
+ file_names.uniq
88
+ end
89
+ end
90
+ end
@@ -18,7 +18,12 @@ module Translator
18
18
  def uri
19
19
  @uri ||= begin
20
20
  uri = URI("https://api.smartling.com/files-api/v2/projects/#{@project_id}/locales/#{@locale_id}/file")
21
- uri.query = URI.encode_www_form({ 'fileUri' => @file_uri, 'retrievalType' => 'published' })
21
+ uri.query = URI.encode_www_form(
22
+ {
23
+ 'fileUri' => @file_uri,
24
+ 'retrievalType' => 'published',
25
+ }
26
+ )
22
27
  uri
23
28
  end
24
29
  end
@@ -31,7 +31,13 @@ module Translator
31
31
  end
32
32
 
33
33
  def return_value
34
- @return_value ||= response_body['response']['data']['items'].map { |item| item['localeId'] }
34
+ @return_value ||= begin
35
+ total_word_count = response_body['response']['data']['totalWordCount']
36
+ total_string_count = response_body['response']['data']['totalStringCount']
37
+ response_body['response']['data']['items'].map do |item|
38
+ item['localeId'] if total_word_count == item['completedWordCount'] && total_string_count == item['completedStringCount']
39
+ end.compact
40
+ end
35
41
  end
36
42
 
37
43
  def to_s
@@ -35,7 +35,7 @@ module Translator
35
35
  dir_path = pathname.dirname.to_s == '.' ? '' : "/#{pathname.dirname}"
36
36
  "#{Rails.configuration.docs_base_path}/config/tutorials/#{locale}#{dir_path}"
37
37
  elsif filename.starts_with? '_tutorials'
38
- pathname = Pathname.new(filename.gsub("_tutorials/#{I18n.default_locale}/", ''))
38
+ pathname = Pathname.new(filename.gsub('_tutorials/', ''))
39
39
  dir_path = pathname.dirname.to_s == '.' ? '' : "/#{pathname.dirname}"
40
40
  "#{Rails.configuration.docs_base_path}/_tutorials/#{locale}#{dir_path}"
41
41
  else
@@ -35,7 +35,7 @@
35
35
  <% step['fields'].each_with_index do |field, field_index| %>
36
36
  <div>
37
37
  <b><%= field['label'] %>:</b>
38
- <small><%= feedback.steps[step_index][field['name']] %></small>
38
+ <small><%= feedback.steps[step_index].try(:[], field['name']) %></small>
39
39
  </div>
40
40
  <% end %>
41
41
  <% end %>
@@ -126,6 +126,16 @@ They auto-magically color when you use verbs like [POST] or [DELETE]
126
126
  |
127
127
  | Nullam id dolor id nibh ultricies vehicula ut id elit. Donec ullamcorper nulla non metus auctor fringilla. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus.
128
128
 
129
+ ````
130
+ | ### Click me
131
+ |
132
+ | Here is some hidden content.
133
+ |
134
+ | Markdown _still_ works `here`!
135
+ |
136
+ | Nullam id dolor id nibh ultricies vehicula ut id elit. Donec ullamcorper nulla non metus auctor fringilla. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus.
137
+ ````
138
+
129
139
  | ### Alpha
130
140
  |
131
141
  | Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Donec id elit non mi porta gravida at eget metus. Sed posuere consectetur est at lobortis. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ullamcorper nulla non metus auctor fringilla.
@@ -134,14 +144,32 @@ They auto-magically color when you use verbs like [POST] or [DELETE]
134
144
  |
135
145
  | Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Donec id elit non mi porta gravida at eget metus. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae elit libero, a pharetra augue. Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Aenean lacinia bibendum nulla sed consectetur. Nullam quis risus eget urna mollis ornare vel eu leo.
136
146
 
147
+ ````
148
+ | ### Alpha
149
+ |
150
+ | Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Donec id elit non mi porta gravida at eget metus. Sed posuere consectetur est at lobortis. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ullamcorper nulla non metus auctor fringilla.
151
+ |
152
+ | Donec id elit non mi porta gravida at eget metus. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Nulla vitae elit libero, a pharetra augue. Donec sed odio dui. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Cras mattis consectetur purus sit amet fermentum.
153
+ |
154
+ | Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Donec id elit non mi porta gravida at eget metus. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla vitae elit libero, a pharetra augue. Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Aenean lacinia bibendum nulla sed consectetur. Nullam quis risus eget urna mollis ornare vel eu leo.
155
+ ````
156
+
137
157
  **Tooltips (custom plugin)**
138
158
 
139
159
  Find out ^[more](Tooltips are useful for when you have more information to convey, but don't want to break context.).
140
160
 
161
+ ````
162
+ Find out ^[more](Tooltips are useful for when you have more information to convey, but don't want to break context.).
163
+ ````
164
+
141
165
  ## Images
142
166
 
143
167
  ![Please always add alt-text](https://media.giphy.com/media/pDTLSpqNvNxlu/giphy.gif)
144
168
 
169
+ ````
170
+ ![Please always add alt-text](https://media.giphy.com/media/pDTLSpqNvNxlu/giphy.gif)
171
+ ````
172
+
145
173
  > Images should be used sparingly, try to avoid using screenshots that might go out of date.
146
174
  >
147
175
  > Also... Please ALWAYS write descriptive alt text.
@@ -183,8 +211,6 @@ See our detailed [code examples guide](/contribute/guides/code-examples) for adv
183
211
  ## Tables
184
212
 
185
213
  > Pipes should only be between cells. Two hyphens `--` should be used to 'underline' the headings.
186
- >
187
- > You'll have to view the `markdown-guide.md` source to see how since showing you the syntax would result in it being processed.
188
214
 
189
215
  | Key | Description |
190
216
  | ------------ | ------------------------------------------------------------------------------------------ |
@@ -192,6 +218,14 @@ See our detailed [code examples guide](/contribute/guides/code-examples) for adv
192
218
  | `API_KEY` | You can find this in your [account overview](https://dashboard.nexmo.com/account-overview) |
193
219
  | `API_SECRET` | You can find this in your [account overview](https://dashboard.nexmo.com/account-overview) |
194
220
 
221
+ ````
222
+ | Key | Description |
223
+ | ------------ | ------------------------------------------------------------------------------------------ |
224
+ | `TO_NUMBER` | The number you are sending the SMS to |
225
+ | `API_KEY` | You can find this in your [account overview](https://dashboard.nexmo.com/account-overview) |
226
+ | `API_SECRET` | You can find this in your [account overview](https://dashboard.nexmo.com/account-overview) |
227
+ ````
228
+
195
229
  ## Tabbed Content (custom plugin)
196
230
 
197
231
  To use the tabbed content block, add a section like this to your markdown to point out where the directory holding the examples is:
@@ -70,7 +70,7 @@
70
70
  { name: 'Neutral', color: '#e1e2e6', data: @feedbacks.neutral.group_by_week('feedback_feedbacks.created_at').count },
71
71
  { name: 'Negative', color: '#ea5353', data: @feedbacks.negative.group_by_week('feedback_feedbacks.created_at').count },
72
72
  ],
73
- stacked: true
73
+ stacked: true, defer: true
74
74
  ) %>
75
75
 
76
76
  <%
@@ -109,7 +109,7 @@
109
109
  { name: 'Neutral', color: '#e1e2e6', data: neutral },
110
110
  { name: 'Negative', color: '#ea5353', data: negative },
111
111
  ],
112
- stacked: true
112
+ stacked: true, defer: true
113
113
  ) %>
114
114
 
115
115
  <hr>
@@ -76,11 +76,6 @@
76
76
  <%= javascript_include_tag 'application', defer: true %>
77
77
 
78
78
  <%= javascript_packs_with_chunks_tag 'application', defer: true %>
79
- <% if @additional_scripts %>
80
- <% @additional_scripts.each do |script| %>
81
- <%= javascript_include_tag script %>
82
- <% end %>
83
- <% end %>
84
79
 
85
80
  <% if ENV['ENVIRONMENT_SCRIPTS'] %>
86
81
  <%= ENV['ENVIRONMENT_SCRIPTS'].html_safe %>
@@ -1,31 +1,34 @@
1
1
  <div class="Nxd-products-list">
2
2
  <div class="Vlt-grid Vlt-grid--center Vlt-grid--margin-top2">
3
+
4
+
3
5
  <div class="Vlt-col Vlt-col--1of3 Vlt-col--M-1of2">
4
6
  <div class="Vlt-card Vlt-article--reverse Vlt-card--image Nxd-card--products">
5
7
  <div class="Vlt-card__content">
6
8
  <svg class="Vlt-icon Vlt-icon--larger Vlt-purple-dark"><use xlink:href="/symbol/volta-icons.svg#Vlt-icon-message" /></svg>
7
- <div class="Nxd-card--product__subtitle"><small>SEND AND RECEIVE</small></div>
8
-
9
+ <div class="Nxd-card--product__subtitle"><small>PRODUCT AREA</small></div>
9
10
  <h2>
10
11
  <a href="/messaging/sms/overview">
11
- SMS
12
+ PRODUCT NAME
12
13
  </a>
13
14
  </h2>
14
15
  <nav>
15
- <a href="/messaging/sms/overview"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
16
+ <a href="#"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
16
17
  aria-hidden="true">
17
- <use xlink:href="/symbol/volta-icons.svg#Vlt-icon-home" /></svg>Overview</a>
18
- <a href="/messaging/sms/guides"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
18
+ <use xlink:href="/symbol/volta-icons.svg#Vlt-icon-home" /></svg>Product Topic 1</a>
19
+ <a href="#"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
19
20
  aria-hidden="true">
20
- <use xlink:href="/symbol/volta-icons.svg#Vlt-icon-books" /></svg>Guides</a>
21
- <a href="/messaging/sms/code-snippets"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
21
+ <use xlink:href="/symbol/volta-icons.svg#Vlt-icon-books" /></svg>Product Topic 2</a>
22
+ <a href="#"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
22
23
  aria-hidden="true">
23
- <use xlink:href="/symbol/volta-icons.svg#Vlt-icon-code" /></svg>Code Snippets</a>
24
- <a href="/messaging/sms/tutorials"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
24
+ <use xlink:href="/symbol/volta-icons.svg#Vlt-icon-code" /></svg>Product Topic 3</a>
25
+ <a href="#"><svg class="Vlt-icon Vlt-icon--small Vlt-icon--text-bottom Vlt-gray-darker"
25
26
  aria-hidden="true">
26
27
  <use xlink:href="/symbol/volta-icons.svg#Vlt-icon-mockup" /></svg>Tutorials</a>
27
28
  <hr class="hr--short">
28
- <a href="/api/sms">API Reference</a>
29
+ <a href="https://nexmo.github.io/station/How-To-Use#customization-options">
30
+ To modify this view, copy <a href="https://raw.githubusercontent.com/Nexmo/station/master/lib/nexmo_developer/app/views/static/_products.html.erb">the file</a> to your `custom/views/static` folder and customize the copied file.
31
+ </a>
29
32
  </nav>
30
33
  </div>
31
34
  </div>