diff --git a/web/Gemfile.lock b/web/Gemfile.lock index 03fcf0042..ec30059e5 100644 --- a/web/Gemfile.lock +++ b/web/Gemfile.lock @@ -936,7 +936,7 @@ DEPENDENCIES zip-codes RUBY VERSION - ruby 2.4.1p111 + ruby 2.3.1p112 BUNDLED WITH 1.17.3 diff --git a/web/app/assets/images/content/button_download_windows.png b/web/app/assets/images/content/button_download_windows.png index fd240ee35..b55ccdc13 100644 Binary files a/web/app/assets/images/content/button_download_windows.png and b/web/app/assets/images/content/button_download_windows.png differ diff --git a/web/app/assets/javascripts/web/downloads.js b/web/app/assets/javascripts/web/downloads.js index 598c8edde..8487c63e0 100644 --- a/web/app/assets/javascripts/web/downloads.js +++ b/web/app/assets/javascripts/web/downloads.js @@ -9,6 +9,18 @@ var downloadUris = {}; // map of platform > uri var rest = context.JK.Rest(); + + // We use this method to detect M1 macs and set appropriate API values to prevent sites from detecting fingerprinting protections + function isAppleSilicon () { + var canvas = document.createElement('canvas'); + var gl = canvas.getContext('webgl'); + + // Best guess if the device is an Apple Silicon + // https://stackoverflow.com/a/65412357 + // @ts-expect-error - Object is possibly 'null' + return gl.getSupportedExtensions().indexOf('WEBGL_compressed_texture_etc') !== -1 + } + function selectPlatform(selectedPlatform) { //console.log("selectedPlatform", selectedPlatform); var platformName; // mac, windows, linux @@ -18,33 +30,34 @@ var uri = downloadUris[selectedPlatform]; // prepare template varaibles - if (selectedPlatform == "Unix") { - platformName = "linux"; - platformDisplay = "Linux" - platformName1 = "mac"; - platformDisplay1 = "Mac"; + if (selectedPlatform == "MacOSX_MX") { + platformName = "mac_mx"; + platformDisplay = "Mac/M1,M2...MX"; + platformName1 = "mac_intel"; + platformDisplay1 = "Mac/Intel"; platformName2 = "windows"; platformDisplay2 = "Windows"; - platform1 = "MacOSX"; + platform1 = "MacOSX_Intel"; platform2 = "Win32" } else if(selectedPlatform == "Win32") { platformName = "windows"; platformDisplay = "Windows"; - platformName1 = "mac"; - platformDisplay1 = "Mac"; - platformName2 = "linux" - platformDisplay2 = "Linux"; - platform1 = "MacOSX"; - platform2 = "Unix"; - } else if(selectedPlatform == "MacOSX") { - platformName = "mac"; - platformDisplay = "Mac"; + platformName1 = "mac_intel"; + platformDisplay1 = "Mac/Intel"; + platformName2 = "mac_mx" + platformDisplay2 = "Mac/M1,M2...MX"; + platform1 = "MacOSX_Intel"; + platform2 = "MacOSX_MX"; + } else if(selectedPlatform == "MacOSX_Intel") { + console.log("IM MACOSXINTEL"); + platformName = "mac_intel"; + platformDisplay = "Mac/Intel"; platformName1 = "windows"; platformDisplay1 = "Windows"; - platformName2 = "linux"; - platformDisplay2 = "Linux"; + platformName2 = "mac_mx"; + platformDisplay2 = "Mac/M1,M2...MX"; platform1 = "Win32"; - platform2 = "Unix"; + platform2 = "MacOSX_MX"; } else { alert("unknown platform: " + selectedPlatform); @@ -75,7 +88,6 @@ $('div.hidden-images img[data-purpose=' + platformName1 + ']', selectOthers).remove().appendTo($('a[data-order=1]', selectOthers)); $('div.hidden-images img[data-purpose=' + platformName2 + ']', selectOthers).remove().appendTo($('a[data-order=2]', selectOthers)); - // install click handler for change selection $('a', selectOthers).click(function() { var platform = $(this).attr('data-platform'); @@ -104,6 +116,8 @@ // update blurb $('body.web .downloads-blurb').empty().append(blurb); + context.JK.popExternalLinks(blurb); + // update the 'download other platforms' buttons $('body.web .downloads-container').empty().append(selectOthers); // update system requirements @@ -144,6 +158,18 @@ var currentOS = context.JK.detectOS(); var downloads = $('.downloads'); + if(currentOS == "MacOSX") { + var silicon = isAppleSilicon(); + if(silicon == true) { + currentOS = "MacOSX_MX"; + } + else { + currentOS = "MacOSX_Intel"; + } + } + console.log("CURRENT OS ", currentOS) + + rest.getClientDownloads() .done(function(data) { //console.log('getClientDownloads', data); diff --git a/web/app/assets/javascripts/web/web.js b/web/app/assets/javascripts/web/web.js index 241f5fd8f..b0c3d3711 100644 --- a/web/app/assets/javascripts/web/web.js +++ b/web/app/assets/javascripts/web/web.js @@ -69,6 +69,7 @@ //= require landing/signup //= require recordingModel //= require web/downloads +//= require web/downloads_legacy //= require web/congratulations //= require web/sessions //= require web/session_info diff --git a/web/app/assets/stylesheets/web/downloads.scss b/web/app/assets/stylesheets/web/downloads.scss index 68b180b83..ccf024030 100644 --- a/web/app/assets/stylesheets/web/downloads.scss +++ b/web/app/assets/stylesheets/web/downloads.scss @@ -13,8 +13,18 @@ body.downloads { .badge-number { display:none; } + .download-container.legacy { + .downloads-blurb { + margin-top:20px; + } + .download-others { + p { + margin:0; + } + } + } .download-app { - left:22.5%; + left:20%; float:none; position:relative; } @@ -33,7 +43,6 @@ body.downloads { color:#CCC; font-size:14px; line-height:125%; - text-indent:-5px; margin-left:40px; &:before @@ -52,7 +61,7 @@ body.downloads { .download-app { padding-top:20px; - width:55%; + width:60%; float:left; @include border_box_sizing; } @@ -97,9 +106,9 @@ body.downloads { } .download-entreaty { - + margin-bottom:25px; p.click-to-download { - margin-bottom:5px; + } } @@ -120,7 +129,7 @@ body.downloads { } ul li { - font-size:12px; + font-size:14px; margin-left:15px; } @@ -134,7 +143,12 @@ body.downloads { .download-box { color:#fff; - text-align:center; + text-align:left; + line-height:135%; + } + + .download-legacy-backup { + margin-top:20px; } .go-jamtrack-shopping { diff --git a/web/app/controllers/users_controller.rb b/web/app/controllers/users_controller.rb index 6847087d8..d4f5109d2 100644 --- a/web/app/controllers/users_controller.rb +++ b/web/app/controllers/users_controller.rb @@ -232,6 +232,14 @@ class UsersController < ApplicationController render rend[:template], :layout => rend[:layout] end + def downloads_legacy + @no_user_dropdown = true + @page_context = 'standalone' + render :layout => 'web' + # rend = _render('downloads_legacy') + #render rend[:template], :layout => rend[:layout] + end + def downloads2021 render :downloads2021, layout: 'jk2021' end diff --git a/web/app/views/users/_download_templates.html.slim b/web/app/views/users/_download_templates.html.slim index 828738a10..0368dc5a0 100644 --- a/web/app/views/users/_download_templates.html.slim +++ b/web/app/views/users/_download_templates.html.slim @@ -8,40 +8,57 @@ script type="text/template" id="client-download-blurb-contents" h5 SYSTEM REQUIREMENTS: | {% if(data.platform == "Win32") { %} ul.windows-requirements - li Windows 7, 8, or 10 - 64-bit (32-bit not supported) + li Windows 10 or 11 - 64-bit (32-bit not supported) li Dual core processor or higher li 75MB hard disk space for app - li External audio interface recommended (but you can start with built-in mic and & headphone jack) - li USB 2.0, USB 3.0, Thunderbolt, or Firewire (not USB 1.1) for external audio interfaces - li Ethernet port for real-time online sessions (WiFi not recommended) - li Broadband Internet service with 1Mbps uplink bandwidth for real-time online sessions - | {% } else if(data.platform == "MacOSX") { %} + li + span External audio interface for audio processing ( + a rel="external" href="https://jamkazam.freshdesk.com/support/solutions/articles/66000122514-audio-interfaces-for-windows-computers" see recommendations if you don't have one + span ) + li USB 2.0, USB 3.0, or USB-C (not USB 1.1) for audio interface + li Ethernet port and Ethernet cable to connect directly to home router (WiFi not recommended) + li Broadband Internet service with 1Mbps upload bandwidth (3-5Mbps preferred) + | {% } else if(data.platform == "MacOSX_Intel") { %} ul.mac-requirements - li Mac OS X 10.8 or higher, 64-bit - li Dual-core processor or higher + li macOS 10.15 (Catalina) or higher, 64-bit li 75MB hard disk space for app - li External audio interface recommended (but you can start with built-in mic and & headphone jack) - li USB 2.0, USB 3.0, Thunderbolt, or Firewire (not USB 1.1) for external audio interfaces - li Ethernet port for real-time online sessions (WiFi not recommended) - li Broadband Internet service with 1Mbps uplink bandwidth for real-time online sessions + li + span External audio interface for audio processing ( + a rel="external" href="https://jamkazam.freshdesk.com/support/solutions/articles/66000122513-audio-interfaces-for-mac-computers" see recommendations if you don't have one + span ) + li USB 2.0, USB 3.0, or USB-C (not USB 1.1) for audio interface + li Ethernet port and Ethernet cable to connect directly to home router (WiFi not recommended) + li Broadband Internet service with 1Mbps upload bandwidth (3-5Mbps preferred) | {% } else { %} - ul.linux-requirements - li Linux is not yet supported + ul.mac-requirements + li macOS 10.15 (Catalina) or higher, 64-bit + li 75MB hard disk space for app + li + span External audio interface for audio processing ( + a rel="external" href="https://jamkazam.freshdesk.com/support/solutions/articles/66000122513-audio-interfaces-for-mac-computers" see recommendations if you don't have one + span ) + li USB 2.0, USB 3.0, or USB-C (not USB 1.1) for audio interface + li Ethernet port and Ethernet cable to connect directly to home router (WiFi not recommended) + li Broadband Internet service with 1Mbps upload bandwidth (3-5Mbps preferred) | {% } %} - + p.download-legacy-backup + | If you have trouble with the new JamKazam app and cannot get things worked out with the help of our support team, you can  + a href="/downloads-legacy" go here + |  to download and re-install the legacy JamKazam app for now. .hidden.hidden-images - = image_tag("content/button_download_mac.png", :alt => "download mac", :size => "348x92", "data-purpose" => "mac") + = image_tag("content/button_download_mac_intel.png", :alt => "download mac (intel)", :size => "348x92", "data-purpose" => "mac_intel") = image_tag("content/button_download_windows.png", :alt => "download windows", :size => "348x92", "data-purpose" => "windows") - = image_tag("content/button_download_linux.png", :alt => "download linux", :size => "348x92", "data-purpose" => "linux") + = image_tag("content/button_download_mac_mx.png", :alt => "download mac (mx)", :size => "348x92", "data-purpose" => "mac_mx") script type="text/template" id="client-download-select-others" .download-box .download-others + span Need a different version? + br a.choose-other-platform href="#" data-order="1" data-platform="{{data.platform1}}" - | Need a different version? - br - | Click here for to get JamKazam - br - | for {{data.platformDisplay1}} ' '' \ No newline at end of file + | JamKazam for {{data.platformDisplay1}} + br + a.choose-other-platform href="#" data-order="2" data-platform="{{data.platform2}}" + | JamKazam for {{data.platformDisplay2}} \ No newline at end of file diff --git a/web/app/views/users/_downloads.html.slim b/web/app/views/users/_downloads.html.slim index 934fa1b05..371ea5597 100644 --- a/web/app/views/users/_downloads.html.slim +++ b/web/app/views/users/_downloads.html.slim @@ -12,15 +12,8 @@ .download-content .download-entreaty - p You need the JamKazam application to: - ul - li Play music with others in real time on the JamKazam platform - li Make audio recordings and share them via Facebook or URL - li Make video recordings and share them via YouTube or URL - li Live broadcast your sessions to family, friends, and fans - li Play and control your JamTracks multi-track recordings + p You must use the JamKazam app to get into online sessions with other musicions. Click the button below to download the JamKazam app installer. Then double click the installer to run it. - p.click-to-download Click the button below to download the JamKazam application installer. .downloads-blurb .jamtracks diff --git a/web/config/routes.rb b/web/config/routes.rb index ff2f89a41..48e8b47d7 100644 --- a/web/config/routes.rb +++ b/web/config/routes.rb @@ -25,6 +25,7 @@ Rails.application.routes.draw do get '/congratulations_musician', to: 'users#congratulations_musician', as: :congratulations_musician get '/congratulations_fan', to: 'users#congratulations_fan' get '/downloads', to: 'users#downloads' + get '/downloads-legacy', to: 'users#downloads_legacy' get '/signin', to: 'sessions#signin' post '/signin', to: 'sessions#create' diff --git a/wordpress/plugins/jamkazam/README.txt b/wordpress/plugins/jamkazam/README.txt index da9059944..f96c78cc6 100644 --- a/wordpress/plugins/jamkazam/README.txt +++ b/wordpress/plugins/jamkazam/README.txt @@ -111,4 +111,4 @@ Titles are optional, naturally. Markdown uses email style notation for blockquotes and I've been told: > Asterisks for *emphasis*. Double it up for **strong**. -`` \ No newline at end of file +``