Add splash page for usage tracking

* Adds a usage cookie
* Only asks for usage on first launch
* will need checking with the official version to make sure the right elements are showing/hiding.
This commit is contained in:
chrisgarrity 2017-08-10 10:00:22 -04:00
parent 3143ec01d4
commit 852df3edbb
10 changed files with 486 additions and 2 deletions

View file

@ -0,0 +1,71 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 21.0.2, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 168 168" enable-background="new 0 0 168 168" xml:space="preserve">
<g>
<g enable-background="new ">
<radialGradient id="SVGID_1_" cx="-144.187" cy="-240.9766" r="78.0882" gradientTransform="matrix(1 0 0 -1 232 -152.9551)" gradientUnits="userSpaceOnUse">
<stop offset="0.5" style="stop-color:#000000"/>
<stop offset="1" style="stop-color:#000000;stop-opacity:0"/>
</radialGradient>
<path fill="url(#SVGID_1_)" d="M87.8,166.1c-43.1,0-78.1-35-78.1-78.1c0-43.1,35-78.1,78.1-78.1c43.1,0,78.1,35,78.1,78.1
C165.9,131.1,130.9,166.1,87.8,166.1z"/>
</g>
<g>
<circle fill="none" stroke="#28A5DA" stroke-width="20" stroke-miterlimit="10" cx="78.8" cy="80" r="68.1"/>
</g>
<circle fill="#F9A737" cx="78.8" cy="80" r="68.1"/>
<linearGradient id="SVGID_2_" gradientUnits="userSpaceOnUse" x1="-153.187" y1="-248.2651" x2="-153.187" y2="-164.8891" gradientTransform="matrix(1 0 0 -1 232 -152.9551)">
<stop offset="0" style="stop-color:#FFFFFF;stop-opacity:0"/>
<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0.5"/>
</linearGradient>
<path fill="url(#SVGID_2_)" d="M146.9,80c0,4.6-30.5,15.3-68.1,15.3C41.2,95.3,10.7,83,10.7,80c0-37.6,30.5-68.1,68.1-68.1
C116.4,11.9,146.9,42.4,146.9,80z"/>
<path display="none" opacity="0.3" fill="#333333" enable-background="new " d="M90.1,137.5L53,131.7l5.6-37.5l0.2,0l0.1-0.7
c0.4-4.1,1.3-13.1,7.1-19.8L41,70l1.6-7.3c2.2-10.1,7-18.5,14-24.1c6.6-5.4,14.9-8.2,24.5-8.2c2.6,0,5.4,0.2,8.3,0.6
c27.7,4.1,36.1,22.9,34.9,37.7l-0.1,0.5c-2.6,17.6-13.6,21.4-21.7,24.1c-1,0.3-1.9,0.6-2.9,1c-3.6,1.3-3.6,1.4-4,4.5l-1,6.9l-0.3,0
L90.1,137.5z"/>
<path display="none" fill="#FFFFFF" d="M88.1,134.5L51,128.7l5.6-37.5l0.2,0l0.1-0.7c0.4-4.1,1.3-13.1,7.1-19.8L39,67l1.6-7.3
c2.2-10.1,7-18.5,14-24.1c6.6-5.4,14.9-8.2,24.5-8.2c2.6,0,5.4,0.2,8.3,0.6c27.7,4.1,36.1,22.9,34.9,37.7l-0.1,0.5
c-2.6,17.6-13.6,21.4-21.7,24.1c-1,0.3-1.9,0.6-2.9,1c-3.6,1.3-3.6,1.4-4,4.5l-1,6.9l-0.3,0L88.1,134.5z"/>
<path display="none" fill="#28A5DA" d="M47.4,61.1C49,53.5,52.7,46.1,58.9,41c6.3-5.2,15.3-7.9,27.3-6.1c24,3.6,29.9,19.2,29,30.3
c-2.3,15.1-11.3,16.3-20,19.5c-6,2.3-7.7,4.4-8.6,10.1l-22.8-3.4c0.5-5.1,1.6-16.5,11.9-20.4c4.1-1.5,12.1-2.3,12.9-7.9
c0.6-4.1-1.6-6.7-6.2-7.3c-5.9-0.9-9,3.8-9.3,9.3L47.4,61.1z M62.6,99.2l22.6,3.5l-3.1,23.7L59,122.8L62.6,99.2z"/>
</g>
<g id="Page-1">
<g id="Tablet-Landscape-v1" transform="translate(-474.000000, -439.000000)">
<g id="Home" transform="translate(450.000000, 415.000000)">
<g id="home-icon" transform="translate(28.000000, 28.000000)">
<g id="Combined-Shape">
<g>
<path id="path-1" fill="#BE8538" d="M51.7,79.8v24.6c0,2.8,2.2,5,5,5h43c2.8,0,5-2.2,5-5V79.7c2.3,1.1,5.1,0.5,6.8-1.5
c2-2.4,1.7-6.1-0.7-8.1L82.2,46c-1.1-0.9-2.5-1.4-3.9-1.3c-1.4,0-2.7,0.4-3.8,1.3l-9.2,7.7v-4.4c0-1.1-0.9-2-2-2h-6
c-1.1,0-2,0.9-2,2v12.7l-9.5,8c-2.4,2-2.8,5.7-0.7,8.1C46.7,80.2,49.5,80.8,51.7,79.8L51.7,79.8z"/>
</g>
<path fill="none" stroke="#BE8538" stroke-width="4" d="M49.7,82.3v22.1c0,3.9,3.1,7,7,7h43c3.9,0,7-3.1,7-7V82.3
c2.4,0.1,4.8-0.8,6.4-2.8c2.8-3.3,2.3-8.2-1-10.9L83.5,44.5c-1.5-1.2-3.3-1.9-5.2-1.8c-1.9,0-3.7,0.6-5.1,1.8l-5.9,5v-0.1
c0-2.2-1.8-4-4-4h-6c-2.2,0-4,1.8-4,4v11.8l-8.8,7.4c-3.3,2.8-3.7,7.7-1,10.9C45.1,81.4,47.4,82.4,49.7,82.3z"/>
</g>
<g id="Combined-Shape_1_">
<g>
<path id="path-2" fill="#FFFFFF" d="M48.7,75.8v24.6c0,2.8,2.2,5,5,5h43c2.8,0,5-2.2,5-5V75.7c2.3,1.1,5.1,0.5,6.8-1.5
c2-2.4,1.7-6.1-0.7-8.1L79.2,42c-1.1-0.9-2.5-1.4-3.9-1.3c-1.4,0-2.7,0.4-3.8,1.3l-9.2,7.7v-4.4c0-1.1-0.9-2-2-2h-6
c-1.1,0-2,0.9-2,2v12.7l-9.5,8c-2.4,2-2.8,5.7-0.7,8.1C43.7,76.2,46.5,76.8,48.7,75.8L48.7,75.8z"/>
</g>
<path fill="none" stroke="#FFFFFF" stroke-width="4" d="M46.7,78.3v22.1c0,3.9,3.1,7,7,7h43c3.9,0,7-3.1,7-7V78.3
c2.4,0.1,4.8-0.8,6.4-2.8c2.8-3.3,2.3-8.2-1-10.9L80.5,40.5c-1.5-1.2-3.3-1.9-5.2-1.8c-1.9,0-3.7,0.6-5.1,1.8l-5.9,5v-0.1
c0-2.2-1.8-4-4-4h-6c-2.2,0-4,1.8-4,4v11.8l-8.8,7.4c-3.3,2.8-3.7,7.7-1,10.9C42.1,77.4,44.4,78.4,46.7,78.3z"/>
</g>
<path id="Rectangle-2" fill="#0FBD8C" d="M48.7,73.4l26.5-21.9l26.5,21.9v27c0,2.8-2.2,5-5,5h-43c-2.8,0-5-2.2-5-5V73.4z"/>
<path id="Rectangle-5" fill="#0B8E69" d="M65.2,83.4c0-1.1,0.9-2,2-2h16c1.1,0,2,0.9,2,2v22h-20V83.4z"/>
<path id="Rectangle-4" fill="#0FBD8C" d="M52.2,45.4c0-1.1,0.9-2,2-2h6c1.1,0,2,0.9,2,2v16h-10V45.4z"/>
<path id="Combined-Shape_2_" fill="#0B8E69" d="M75.3,40.7c1.4,0,2.8,0.4,3.9,1.3l28.7,24.1c2.4,2,2.8,5.7,0.7,8.1
c-2.1,2.4-5.7,2.8-8.1,0.7L75.3,53.8L50.2,74.9c-2.4,2-6.1,1.7-8.1-0.7c-2.1-2.4-1.7-6.1,0.7-8.1L71.5,42
C72.6,41.1,73.9,40.6,75.3,40.7L75.3,40.7z"/>
</g>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 4.9 KiB

View file

@ -0,0 +1,58 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 21.0.2, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 168 168" enable-background="new 0 0 168 168" xml:space="preserve">
<g>
<g enable-background="new ">
<radialGradient id="SVGID_1_" cx="-144.187" cy="-240.9766" r="78.0882" gradientTransform="matrix(1 0 0 -1 232 -152.9551)" gradientUnits="userSpaceOnUse">
<stop offset="0.5" style="stop-color:#000000"/>
<stop offset="1" style="stop-color:#000000;stop-opacity:0"/>
</radialGradient>
<path fill="url(#SVGID_1_)" d="M87.8,166.1c-43.1,0-78.1-35-78.1-78.1c0-43.1,35-78.1,78.1-78.1c43.1,0,78.1,35,78.1,78.1
C165.9,131.1,130.9,166.1,87.8,166.1z"/>
</g>
<g>
<circle fill="none" stroke="#28A5DA" stroke-width="20" stroke-miterlimit="10" cx="78.8" cy="80" r="68.1"/>
</g>
<circle fill="#F9A737" cx="78.8" cy="80" r="68.1"/>
<linearGradient id="SVGID_2_" gradientUnits="userSpaceOnUse" x1="-153.187" y1="-248.2651" x2="-153.187" y2="-164.8891" gradientTransform="matrix(1 0 0 -1 232 -152.9551)">
<stop offset="0" style="stop-color:#FFFFFF;stop-opacity:0"/>
<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0.5"/>
</linearGradient>
<path fill="url(#SVGID_2_)" d="M146.9,80c0,4.6-30.5,15.3-68.1,15.3C41.2,95.3,10.7,83,10.7,80c0-37.6,30.5-68.1,68.1-68.1
C116.4,11.9,146.9,42.4,146.9,80z"/>
<path display="none" opacity="0.3" fill="#333333" enable-background="new " d="M90.1,137.5L53,131.7l5.6-37.5l0.2,0l0.1-0.7
c0.4-4.1,1.3-13.1,7.1-19.8L41,70l1.6-7.3c2.2-10.1,7-18.5,14-24.1c6.6-5.4,14.9-8.2,24.5-8.2c2.6,0,5.4,0.2,8.3,0.6
c27.7,4.1,36.1,22.9,34.9,37.7l-0.1,0.5c-2.6,17.6-13.6,21.4-21.7,24.1c-1,0.3-1.9,0.6-2.9,1c-3.6,1.3-3.6,1.4-4,4.5l-1,6.9l-0.3,0
L90.1,137.5z"/>
<path display="none" fill="#FFFFFF" d="M88.1,134.5L51,128.7l5.6-37.5l0.2,0l0.1-0.7c0.4-4.1,1.3-13.1,7.1-19.8L39,67l1.6-7.3
c2.2-10.1,7-18.5,14-24.1c6.6-5.4,14.9-8.2,24.5-8.2c2.6,0,5.4,0.2,8.3,0.6c27.7,4.1,36.1,22.9,34.9,37.7l-0.1,0.5
c-2.6,17.6-13.6,21.4-21.7,24.1c-1,0.3-1.9,0.6-2.9,1c-3.6,1.3-3.6,1.4-4,4.5l-1,6.9l-0.3,0L88.1,134.5z"/>
<path display="none" fill="#28A5DA" d="M47.4,61.1C49,53.5,52.7,46.1,58.9,41c6.3-5.2,15.3-7.9,27.3-6.1c24,3.6,29.9,19.2,29,30.3
c-2.3,15.1-11.3,16.3-20,19.5c-6,2.3-7.7,4.4-8.6,10.1l-22.8-3.4c0.5-5.1,1.6-16.5,11.9-20.4c4.1-1.5,12.1-2.3,12.9-7.9
c0.6-4.1-1.6-6.7-6.2-7.3c-5.9-0.9-9,3.8-9.3,9.3L47.4,61.1z M62.6,99.2l22.6,3.5l-3.1,23.7L59,122.8L62.6,99.2z"/>
</g>
<title>other-icon</title>
<desc>Created with Sketch.</desc>
<g id="Page-1">
<g id="Tablet-Landscape-v1" transform="translate(-680.000000, -439.000000)">
<g id="Other" transform="translate(648.000000, 415.000000)">
<g id="other-icon" transform="translate(23.300000, 16.243902)">
<path id="Rectangle" fill="#BE8538" stroke="#BE8538" stroke-width="6.3" d="M70,64.3c11.1-11.1,29.1-11.1,40.1,0l0,0
c11.1,11.1,11.1,29.1,0,40.1L90,124.6l-20.1-20.1c-11.1-11.1-11.1-29.1,0-40.1L70,64.3z"/>
<path id="Rectangle_1_" fill="#35A8DF" d="M67,61.3c11.1-11.1,29.1-11.1,40.1,0l0,0c11.1,11.1,11.1,29.1,0,40.1L87,121.6
l-20.1-20.1c-11.1-11.1-11.1-29.1,0-40.1L67,61.3z"/>
<path id="Combined-Shape" fill="#2E91BF" d="M104.5,58.9c0.9,0.7,1.8,1.5,2.7,2.3c11.1,11.1,11.1,29.1,0,40.1L87,121.6
l-12.5-12.5l7.5,7.5l20.2-20.2C112.4,86.2,113.2,70.1,104.5,58.9L104.5,58.9z"/>
<ellipse id="Oval-2" fill="#2E91BF" cx="86.6" cy="80.9" rx="11.7" ry="11.7"/>
<path id="Combined-Shape_1_" fill="#287EA6" d="M79.4,90.1c-2.7-2.1-4.5-5.5-4.5-9.2c0-6.5,5.2-11.7,11.7-11.7
c3.7,0,7.1,1.8,9.2,4.5c-2-1.6-4.5-2.5-7.2-2.5c-6.5,0-11.7,5.2-11.7,11.7C76.9,85.6,77.8,88.1,79.4,90.1L79.4,90.1z"/>
<path id="Rectangle_2_" fill="none" stroke="#FFFFFF" stroke-width="6.3" d="M67,61.3c11.1-11.1,29.1-11.1,40.1,0l0,0
c11.1,11.1,11.1,29.1,0,40.1L87,121.6l-20.1-20.1c-11.1-11.1-11.1-29.1,0-40.1L67,61.3z"/>
</g>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.9 KiB

View file

@ -0,0 +1,112 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 21.0.2, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 168 168" enable-background="new 0 0 168 168" xml:space="preserve">
<g>
<g enable-background="new ">
<radialGradient id="SVGID_1_" cx="-144.187" cy="-240.9766" r="78.0882" gradientTransform="matrix(1 0 0 -1 232 -152.9551)" gradientUnits="userSpaceOnUse">
<stop offset="0.5" style="stop-color:#000000"/>
<stop offset="1" style="stop-color:#000000;stop-opacity:0"/>
</radialGradient>
<path fill="url(#SVGID_1_)" d="M87.8,166.1c-43.1,0-78.1-35-78.1-78.1c0-43.1,35-78.1,78.1-78.1c43.1,0,78.1,35,78.1,78.1
C165.9,131.1,130.9,166.1,87.8,166.1z"/>
</g>
<g>
<circle fill="none" stroke="#28A5DA" stroke-width="20" stroke-miterlimit="10" cx="78.8" cy="80" r="68.1"/>
</g>
<circle fill="#F9A737" cx="78.8" cy="80" r="68.1"/>
<linearGradient id="SVGID_2_" gradientUnits="userSpaceOnUse" x1="-153.187" y1="-248.2651" x2="-153.187" y2="-164.8891" gradientTransform="matrix(1 0 0 -1 232 -152.9551)">
<stop offset="0" style="stop-color:#FFFFFF;stop-opacity:0"/>
<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0.5"/>
</linearGradient>
<path fill="url(#SVGID_2_)" d="M146.9,80c0,4.6-30.5,15.3-68.1,15.3C41.2,95.3,10.7,83,10.7,80c0-37.6,30.5-68.1,68.1-68.1
C116.4,11.9,146.9,42.4,146.9,80z"/>
<path display="none" opacity="0.3" fill="#333333" enable-background="new " d="M90.1,137.5L53,131.7l5.6-37.5l0.2,0l0.1-0.7
c0.4-4.1,1.3-13.1,7.1-19.8L41,70l1.6-7.3c2.2-10.1,7-18.5,14-24.1c6.6-5.4,14.9-8.2,24.5-8.2c2.6,0,5.4,0.2,8.3,0.6
c27.7,4.1,36.1,22.9,34.9,37.7l-0.1,0.5c-2.6,17.6-13.6,21.4-21.7,24.1c-1,0.3-1.9,0.6-2.9,1c-3.6,1.3-3.6,1.4-4,4.5l-1,6.9l-0.3,0
L90.1,137.5z"/>
<path display="none" fill="#FFFFFF" d="M88.1,134.5L51,128.7l5.6-37.5l0.2,0l0.1-0.7c0.4-4.1,1.3-13.1,7.1-19.8L39,67l1.6-7.3
c2.2-10.1,7-18.5,14-24.1c6.6-5.4,14.9-8.2,24.5-8.2c2.6,0,5.4,0.2,8.3,0.6c27.7,4.1,36.1,22.9,34.9,37.7l-0.1,0.5
c-2.6,17.6-13.6,21.4-21.7,24.1c-1,0.3-1.9,0.6-2.9,1c-3.6,1.3-3.6,1.4-4,4.5l-1,6.9l-0.3,0L88.1,134.5z"/>
<path display="none" fill="#28A5DA" d="M47.4,61.1C49,53.5,52.7,46.1,58.9,41c6.3-5.2,15.3-7.9,27.3-6.1c24,3.6,29.9,19.2,29,30.3
c-2.3,15.1-11.3,16.3-20,19.5c-6,2.3-7.7,4.4-8.6,10.1l-22.8-3.4c0.5-5.1,1.6-16.5,11.9-20.4c4.1-1.5,12.1-2.3,12.9-7.9
c0.6-4.1-1.6-6.7-6.2-7.3c-5.9-0.9-9,3.8-9.3,9.3L47.4,61.1z M62.6,99.2l22.6,3.5l-3.1,23.7L59,122.8L62.6,99.2z"/>
</g>
<title>other-icon</title>
<desc>Created with Sketch.</desc>
<title>school-icon</title>
<desc>Created with Sketch.</desc>
<g id="Page-1">
<g id="Tablet-Landscape-v1" transform="translate(-280.000000, -441.000000)">
<g id="School" transform="translate(251.000000, 415.000000)">
<g id="school-icon" transform="translate(34.200000, 31.585366)">
<g id="Path">
<g>
<path id="path-1" fill="#BE8538" d="M93.4,43.1c0.8,0,1.7,0,2.5,0.1c-0.4,3.9-1.9,7.5-4.4,10.5c7,1.8,11.9,8.2,11.9,15.4V70
c-0.3,16-10.5,30.5-18.1,34.3c-0.4,0.2-0.9,0.4-1.3,0.6l-0.5,0.2H83c-0.4,0.1-0.8,0.2-1.2,0.1h-0.6c-2,0.1-4-0.6-5.4-2.1
c-1.4,1.5-3.4,2.3-5.5,2.3h-0.6c-0.4,0-0.8,0-1.2-0.1H68l-0.5-0.2c-0.5-0.1-0.9-0.3-1.3-0.6c-7.7-4-17.8-18.6-18.1-34.5v-0.8
c0-6.6,4-12.5,10.2-14.9c6.1-2.4,13.1-0.8,17.6,4.1c0.4-0.4,0.8-0.9,1.3-1.2c-0.3-8-6-9.6-7.4-9.9l0,0c-0.1,0-0.1,0-0.2,0
C69,47,69,46,69.5,44.9c0.5-1,1.1-1.5,1.6-1.5h0.2c5.6,2,7.2,7.3,7.1,12.3c0.5-3.7,2.3-7.1,5-9.6C86.4,44.1,89.8,43,93.4,43.1
L93.4,43.1z"/>
</g>
<path fill="none" stroke="#BE8538" stroke-width="6.3" d="M72.3,46.2c0,0.1,0,0.1,0,0.2C72.3,46.5,72.3,46.4,72.3,46.2
c0.2-0.1,0.2-0.2,0.2-0.1C72.4,46.1,72.3,46.2,72.3,46.2z M71.3,46.5c-0.1,0-0.1,0-0.2,0L71.3,46.5L71.3,46.5z M71.3,44.7
c0.6,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,45.3,79.3,46.1z"/>
</g>
<g id="Path_1_">
<g>
<path id="path-2" fill="#FFFFFF" d="M90.7,41.3c0.8,0,1.7,0,2.5,0.1c-0.4,3.9-1.9,7.5-4.4,10.5c7,1.8,11.9,8.2,11.9,15.4v0.8
c-0.3,16-10.5,30.5-18.1,34.3c-0.4,0.2-0.9,0.4-1.3,0.6l-0.5,0.2h-0.4c-0.4,0.1-0.8,0.2-1.2,0.1h-0.6c-2,0.1-4-0.6-5.4-2.1
c-1.4,1.5-3.4,2.3-5.5,2.3h-0.6c-0.4,0-0.8,0-1.2-0.1h-0.4l-0.5-0.2c-0.5-0.1-0.9-0.3-1.3-0.6c-7.7-4-17.8-18.6-18.1-34.5
v-0.8c0-6.6,4-12.5,10.2-14.9c6.1-2.4,13.1-0.8,17.6,4.1c0.4-0.4,0.8-0.9,1.3-1.2c-0.3-8-6-9.6-7.4-9.9l0,0
c-0.1,0-0.1,0-0.2,0c-0.5-0.2-0.5-1.3,0-2.3c0.5-1,1.1-1.5,1.6-1.5h0.2c5.6,2,7.2,7.3,7.1,12.3c0.5-3.7,2.3-7.1,5-9.6
C83.7,42.3,87.1,41.2,90.7,41.3L90.7,41.3z"/>
</g>
<path fill="none" stroke="#FFFFFF" stroke-width="5.4" d="M69,44.2c0.1,0.2,0.1,0.3,0.1,0.4c0,0,0-0.1,0.1-0.3
c0.1-0.2,0.2-0.4,0.2-0.4C69.3,44,69.2,44.1,69,44.2z M68.6,44.3c-0.1,0-0.1,0-0.2,0L68.6,44.3L68.6,44.3z M68.6,43.5
c0.2,0.2,0.3,0.4,0.4,0.6c0,0.1,0,0.1,0.1,0.2c-0.1,0-0.3,0.1-0.4,0.1V43.5z M76.5,45.1c-1.7,2.3-2.8,5-3.4,7.9
c0,0.2-0.1,0.4-0.1,0.6l0.8,0.1l4.6,0.3C78.5,50.6,77.9,47.6,76.5,45.1c-1.4-2.7-3.7-4.8-7-6l-0.4-0.2h-0.5h-0.2
c-1.8,0-3.1,1.2-4,3c-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-0.3-1.3-0.6c-7.7-4-17.8-18.6-18.1-34.5v-0.8c0-6.6,4-12.5,10.2-14.9c6.1-2.4,13.1-0.8,17.6,4.1
c4.5-4.8,11.4-6.5,17.5-4.1c6.1,2.4,10.2,8.3,10.2,14.9C100.7,67.7,100.7,68,100.7,68.2z"/>
<path id="Combined-Shape" fill="#D45024" d="M56.3,96.6c2.4,2.8,4.9,5,7.2,6.2c0.4,0.2,0.9,0.4,1.3,0.6l0.5,0.2h0.4
c0.4,0.1,0.8,0.2,1.2,0.1h0.6c2.1,0.1,4-0.8,5.5-2.3c1.4,1.4,3.4,2.2,5.4,2.1h0.6c0.4,0,0.8,0,1.2-0.1h0.4l0.5-0.2
c0.5-0.1,0.9-0.3,1.3-0.6c7.7-3.8,17.8-18.4,18.1-34.3v-0.8h0.1c0-5.3-2.6-10.2-6.9-13.1c1.8,2.6,2.9,5.8,2.9,9.1h-0.1v0.8
c-0.3,16-10.5,30.5-18.1,34.3c-0.4,0.2-0.9,0.4-1.3,0.6l-0.5,0.2h-0.4c-0.4,0.1-0.8,0.2-1.2,0.1h-0.6c-2,0.1-4-0.6-5.4-2.1
c-1.4,1.5-3.4,2.3-5.5,2.3h-0.6c-0.4,0-0.8,0-1.2-0.1h-0.4l-0.5-0.2c-0.5-0.1-0.9-0.3-1.3-0.6C58.4,98.2,57.3,97.5,56.3,96.6
L56.3,96.6z"/>
<path id="_Path_" fill="#FF8C66" d="M59.9,57.8c-3.2-1.4-6.9-0.2-8.6,2.8c-2,3-2,6.9,0,9.9C51.7,65,55,60.2,59.9,57.8L59.9,57.8
z"/>
<path id="Shape_1_" fill="#8A5D3B" d="M66.6,45.4c0.1,0,0.2,0,0.3,0l0,0c1.9,0.4,10.9,3.1,5.9,19h1c0,0,6.6-18.5-5.3-22.8
c-0.5-0.2-1.3,0.4-1.9,1.5C66,44.1,66.1,45.1,66.6,45.4z"/>
<path id="Shape_2_" fill="#37B34A" d="M93.2,41.5L75.3,55.8c0,0,0.5-7.5,5.5-11.5C85.7,40.3,93.2,41.5,93.2,41.5z"/>
<path id="Shape_3_" fill="#009345" d="M87.7,53c-4.9,4-12.4,2.8-12.4,2.8l17.9-14.3C93.2,41.5,92.7,49,87.7,53z"/>
<rect id="Rectangle-path" x="72.3" y="58.3" fill="#F05A28" width="8.5" height="7.5"/>
<path id="_Path_3" fill="#DA4E28" d="M61.3,51.5c4.7,0,9.2,2.1,12.2,5.7c1.6,2,4.9,0,4.9,0c-0.7,1.2-1.9,2.1-3.2,2.3
C70.8,59.5,68.8,51.5,61.3,51.5L61.3,51.5z"/>
</g>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 8.8 KiB

View file

@ -217,3 +217,130 @@ div.frame {
from { -webkit-transform: rotate(0deg); }
to { -webkit-transform: rotate(36deg); }
}
/* Analytics Info Page Elements */
.usageQuestion {
position: absolute;
width: 60%;
height: 35%;
top: 15%;
left: 20%;
color: white;
font-size: 5em;
font-weight: 500;
text-align: center;
text-shadow: 1px 1px 4px #333333;
}
.usageQuestion.hide {display: none;}
.usageQuestion.show {display: block;}
.usageIcon {
width: 100%;
margin-left: 3%;
}
.usageText {
color: #999999;
font-size: 2em;
text-align: center;
margin-top: .5em;
}
.usageSchool {
position: absolute;
top: 45%;
left: 17%;
margin: 0px;
width: 17%;
height: 30%;
-webkit-tap-highlight-color: transparent;
z-index: 1000;
}
.usageSchool.hide {display: none;}
.usageSchool.show {display: block;}
.usageHome {
position: absolute;
top: 45%;
left: 42%;
width: 17%;
height: 30%;
margin: 0px;
-webkit-tap-highlight-color: transparent;
z-index: 1000;
}
.usageHome.hide {display: none;}
.usageHome.show {display: block;}
.usageOther {
position: absolute;
top: 45%;
left: 67%;
margin: 0px;
width: 17%;
height: 22%;
-webkit-tap-highlight-color: transparent;
z-index: 1000;
}
.usageOther.hide {display: none;}
.usageOther.show {display: block;}
.usageNoanswer {
position: absolute;
width: 50%;
height: 15%;
top: 90%;
left: 25%;
text-align: center;
z-index: 25;
}
.usageNoanswerText {
color: #35A8E0;
font-size: 1.8em;
}
.usageNoanswer.hide {display: none;}
.usageNoanswer.show {display: block;}
/* TODO: make font sizes relative!! */
/* Usage text boxes */
.usage-text {
position: absolute;
width: 20%;
height: 15%;
top: 75%;
background-color: #35A8E0;
border: none;
color: white;
font-size: 35px;
text-align: center;
text-decoration: none;
overflow: hidden;
white-space: nowrap;
}
.usage-text.school {
left: 10%;
}
.usage-text.home {
left: 40%;
}
.usage-text.other {
left: 70%;
}
.usage-text.dont-ask {
top: 90%;
right: 2%;
height: 10%;
width: 20%;
font-size: 20px;
text-align: right;
}

View file

@ -38,6 +38,23 @@
<div class="gettings hide" id="gettings"></div>
<div class="startcode hide" id="startcode"></div>
<div class="usageQuestion hide" id="usageQuestion"></div>
<div class="usageSchool hide" id="usageSchool">
<img class="usageIcon" id="useSchoolIcon" src="assets/start/schoolIcon.svg" />
<div class="usageText" id="useSchoolText"></div>
</div>
<div class="usageHome hide" id="usageHome">
<img class="usageIcon" id="useHomeIcon" src="assets/start/homeIcon.svg" />
<div class="usageText" id="useHomeText"></div>
</div>
<div class="usageOther hide" id="usageOther">
<img class="usageIcon" id="useOtherIcon" src="assets/start/otherIcon.svg" />
<div class="usageText" id="useOtherText"></div>
</div>
<div class="usageNoanswer hide" id="usageNoanswer">
<div class="usageNoanswerText" id="usageNoanswerText"></div>
</div>
</div>
</body>
</html>

View file

@ -370,5 +370,10 @@
"SAY_BLOCK_DEFAULT_ARGUMENT": "hi",
"ALERT_BACK": "Back",
"ALERT_SAVING": "Saving...",
"SELECT_LANGUAGE": "Select language"
"SELECT_LANGUAGE": "Select language",
"USAGE_QUESTION": "Where are you using ScratchJr?",
"USAGE_SCHOOL": "School",
"USAGE_HOME": "Home",
"USAGE_OTHER": "Other",
"USAGE_NONE": "Don't ask again"
}

View file

@ -1,5 +1,6 @@
import {preprocessAndLoadCss} from '../utils/lib';
import Localization from '../utils/Localization';
import AppUsage from '../utils/AppUsage';
import iOS from '../iPad/iOS';
import IO from '../iPad/IO';
import MediaLib from '../iPad/MediaLib';
@ -109,5 +110,7 @@ window.onload = () => {
entryFunction();
});
});
// Initialize currentUsage data
AppUsage.initUsage();
});
};

View file

@ -3,6 +3,7 @@ import {gn, getUrlVars, isAndroid, isiOS} from '../utils/lib';
import iOS from '../iPad/iOS';
import UI from '../editor/ui/UI';
import Localization from '../utils/Localization';
import AppUsage from '../utils/AppUsage';
export function indexMain () {
gn('gettings').ontouchend = indexGettingstarted;
@ -63,6 +64,14 @@ function indexFirstTime () {
}
function indexLoadOptions () {
if (window.Settings.edition != 'PBS' && AppUsage.askForUsage()) {
indexLoadUsage();
} else {
indexLoadStart();
}
}
function indexLoadStart () {
gn('authors').className = 'credits hide';
gn('authorsText').className = 'creditsText hide';
@ -86,6 +95,30 @@ function indexLoadOptions () {
}
}
function indexLoadUsage () {
gn('authors').className = 'credits show';
gn('authorsText').className = 'creditsText hide';
gn('purpleguy').className = 'purple hide';
gn('blueguy').className = 'blue hide';
gn('redguy').className = 'red hide';
gn('usageQuestion').textContent = Localization.localize('USAGE_QUESTION');
gn('useSchoolText').textContent = Localization.localize('USAGE_SCHOOL');
gn('useHomeText').textContent = Localization.localize('USAGE_HOME');
gn('useOtherText').textContent = Localization.localize('USAGE_OTHER');
gn('usageNoanswerText').textContent = Localization.localize('USAGE_NONE');
gn('usageQuestion').className = 'usageQuestion show';
gn('usageSchool').className = 'usageSchool show';
gn('usageHome').className = 'usageHome show';
gn('usageOther').className = 'usageOther show';
gn('usageNoanswer').className = 'usageNoanswer show';
gn('usageSchool').ontouchend = indexSetUsage;
gn('usageHome').ontouchend = indexSetUsage;
gn('usageOther').ontouchend = indexSetUsage;
gn('usageNoanswer').ontouchend = indexSetUsage;
}
function indexGohome () {
iOS.setfile('homescroll.sjr', 0, function () {
doNext();
@ -107,6 +140,29 @@ function indexGettingstarted () {
window.location.href = 'gettingstarted.html?place=home';
}
function indexSetUsage (e) {
var usageText = '';
switch (e.target.parentElement.id) {
case 'usageSchool':
usageText = 'school';
break;
case 'usageHome':
usageText = 'home';
break;
case 'usageOther':
usageText = 'other';
break;
case 'usageNoanswer':
usageText = 'noanswer';
break;
}
// Send one-time analytics event about usage
iOS.analyticsEvent('lobby', 'scratchjr_usage', usageText);
AppUsage.setUsage(usageText);
ScratchAudio.sndFX('tap.wav');
window.location.href = 'index.html';
}
// For PBS KIDS edition only
function indexInfo () {
ScratchAudio.sndFX('tap.wav');

View file

@ -3,6 +3,7 @@ import IO from './IO';
import Lobby from '../lobby/Lobby';
import Alert from '../editor/ui/Alert';
import ScratchAudio from '../utils/ScratchAudio';
import AppUsage from '../utils/AppUsage';
//////////////////////////////////////////////////
// Tablet interface functions
@ -358,7 +359,8 @@ export default class iOS {
if (!value) {
value = 1;
}
tabletInterface.analyticsEvent(category, action, label, value);
let newCategory = category + AppUsage.currentUsage;
tabletInterface.analyticsEvent(newCategory, action, label, value);
}
// Web Wiew delegate call backs

33
src/utils/AppUsage.js Normal file
View file

@ -0,0 +1,33 @@
import Cookie from './Cookie';
let currentUsage;
export default class AppUsage {
static get currentUsage () {
return currentUsage;
}
static initUsage () {
var usageCookie = Cookie.get('usage');
if (usageCookie === null || usageCookie === 'noanswer') {
currentUsage = '';
} else {
currentUsage = '_' + usageCookie;
}
}
static askForUsage () {
var usageCookie = Cookie.get('usage');
return usageCookie === null;
}
static setUsage (kind) {
if (kind === '') {
Cookie.set('usage', 'noanswer');
} else {
Cookie.set('usage', kind);
}
currentUsage = kind === 'noanswer' ? '' : '_' + kind;
}
}