Skip to content

Commit

Permalink
Merge pull request #1134 from appirio-tech/dev
Browse files Browse the repository at this point in the history
Remove april banner and font fixes for listings
  • Loading branch information
ajefts authored Apr 3, 2017
2 parents 01e24d5 + 10187f1 commit 4e6b596
Show file tree
Hide file tree
Showing 56 changed files with 8,126 additions and 0 deletions.
131 changes: 131 additions & 0 deletions app/fontTest/fontTest.jade
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
h1 Fonts Test
p This is a simple showcase of the fonts included into this repo,
| and a test of their proper packing into the bundle.
.roboto-thin
h3 Roboto Thin
| Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas
| semper consectetur dui, nec scelerisque lectus hendrerit a. Curabitur
| eget imperdiet orci. Sed non tincidunt turpis, laoreet fringilla nisl.
| Suspendisse tincidunt ligula arcu, nec hendrerit erat ultricies et. Nam
| elit nisl, pharetra in leo a, posuere facilisis lacus. Vivamus mollis
| est ac justo pulvinar iaculis sed ac ex. Cras et maximus enim, eget
| posuere ante. Cras in viverra quam. Sed lacinia rutrum semper. Praesent
| mollis turpis elit, vel feugiat nisl sollicitudin nec. Cras ex quam,
| facilisis eu placerat ac, vehicula a nulla. Vivamus et tellus in est
| hendrerit rhoncus et a leo. Donec dui lorem, laoreet nec malesuada sed,
| dictum ut elit. Nullam pretium augue vel odio ultrices, ut commodo
| lacus imperdiet. Integer maximus imperdiet odio, non dignissim lorem
| sollicitudin nec. Sed sed cursus metus.
.roboto-thin-italic
h3 Roboto Thin Italic
| Praesent quam arcu, ultricies et dolor sed, interdum gravida nibh.
| Proin scelerisque porttitor nibh, nec finibus nibh interdum sit amet.
| Duis luctus sapien nec velit sollicitudin convallis. Ut eget neque vel
| nibh lacinia commodo. In ut lorem id quam molestie blandit. Integer in
| nunc cursus, suscipit sem id, accumsan mi. Sed luctus, quam sit amet
| fringilla feugiat, nisl lacus pretium nunc, et elementum est odio et
| risus. Praesent quis cursus urna. Ut orci elit, rutrum id accumsan
| luctus, cursus sed dui. Phasellus lorem urna, mattis et mauris sit amet,
| tristique hendrerit sapien.
.roboto-light
h3 Roboto Light
| Sed nec dolor blandit, commodo arcu in, tincidunt nulla. In in odio id
| arcu luctus aliquet non in mi. Ut efficitur, lorem eget mollis tempus,
| ligula purus varius massa, a malesuada diam urna placerat leo. Sed quis
| diam ullamcorper, fringilla augue sed, hendrerit felis. Sed eget felis
| ac nulla feugiat gravida. Donec a sem lobortis, pulvinar nibh eu,
| convallis magna. Suspendisse tempus tincidunt dolor, id blandit est
| lacinia eu. Nam fermentum, sapien at dictum consectetur, felis neque
| mollis libero, at auctor nunc nunc eu tellus. Maecenas ultrices at
| neque eget tincidunt. Nullam vel consequat nunc, eget efficitur quam.
| Nam nec elit vitae metus cursus eleifend semper aliquet diam.
.roboto-light-italic
h3 Roboto Light Italic
| Nulla suscipit dui et placerat vulputate. Nunc et tempus neque, eget
| elementum elit. Integer vitae dignissim tellus, et venenatis nulla.
| Vivamus non lacus et ipsum imperdiet interdum tempus ullamcorper leo.
| Phasellus tempus magna imperdiet sagittis viverra. Curabitur varius
| elementum auctor. Nullam quam nisl, vestibulum et magna pharetra,
| vestibulum placerat leo. Aliquam faucibus maximus urna, sed mattis ex
| pretium in. Nam eu enim vitae massa vestibulum iaculis. Quisque nec
| risus varius, eleifend urna non, ornare est. Curabitur gravida tempus
| eros, posuere pellentesque magna euismod sed. Donec sed justo ut dolor
| accumsan gravida vitae nec neque. Proin ac tellus dui. Integer ac
| euismod massa.
.roboto-regular
h3 Roboto Regular
| Morbi a urna maximus, imperdiet ante id, rutrum sem. Nunc fermentum
| ante sodales convallis placerat. Donec eleifend, metus eget congue
| semper, lorem nibh vehicula velit, eu sollicitudin mi orci eget purus.
| Pellentesque accumsan fermentum arcu et hendrerit. Donec non porta
| purus. Vivamus eu venenatis sapien. Nullam et mi at eros finibus
| ultrices eget sit amet est. Curabitur non diam ornare est dapibus
| tempor a ut turpis. Nulla ut nibh metus. Vivamus hendrerit turpis nisl,
| eget fermentum nulla egestas quis.
.roboto-regular-italic
h3 Roboto Regular Italic
| Nam vel ligula in ipsum condimentum sodales. Praesent id lorem tortor.
| In vel condimentum leo, nec rhoncus elit. Sed accumsan metus vitae diam
| ultricies, eu vestibulum metus pretium. Nullam congue, purus a tempor
| venenatis, leo dui blandit nibh, nec fermentum ante eros ac ipsum.
| Maecenas id neque ligula. Ut vitae faucibus lectus, vel tempus ipsum.
| Donec ut erat lobortis, vestibulum enim vel, scelerisque turpis.
| Aliquam ornare velit at elementum euismod.
.roboto-medium
h3 Roboto Medium
| Ut laoreet rhoncus vulputate. Quisque elementum quam justo, ac eleifend
| mauris viverra eget. Nunc sit amet commodo est. Nullam scelerisque elit
| ac porttitor finibus. Sed laoreet urna non enim molestie, iaculis
| suscipit felis commodo. Vestibulum gravida ante porttitor urna
| hendrerit, quis dapibus sem viverra. Praesent consectetur risus ac
| finibus varius. Ut commodo felis vel laoreet ornare. Donec imperdiet
| sagittis efficitur. Nunc in dui id ligula blandit vehicula a id leo. In
| pulvinar felis eget tortor pretium pulvinar. Integer a mi a justo
| sagittis finibus ac eget nisl. In eu dictum lectus, eu accumsan purus.
.roboto-medium-italic
h3 Roboto Medium Italic
| Class aptent taciti sociosqu ad litora torquent per conubia nostra, per
| inceptos himenaeos. Vestibulum eget eros malesuada lacus porta
| scelerisque. Integer in dolor et metus dictum faucibus sit amet a
| mauris. Vivamus eget volutpat nulla, non posuere sapien. Vivamus mattis
| vehicula justo eu faucibus. Nunc eleifend mollis ultricies. Integer
| elementum ipsum eu nisi sodales, eget ornare quam posuere. Maecenas sit
| amet sem mattis, porttitor neque ut, molestie velit.
.roboto-bold
h3 Roboto Bold
| Nulla quis cursus orci. Mauris metus enim, volutpat id diam ac,
| fermentum dapibus augue. Donec mi elit, volutpat eget rutrum non,
| lobortis ac enim. In tempus iaculis turpis, vitae facilisis quam
| vehicula eget. Ut blandit, elit at porta vulputate, orci ipsum
| fermentum nunc, non dignissim lectus metus a velit. In hac habitasse
| platea dictumst. Mauris tincidunt, sem quis interdum ullamcorper, erat
| velit interdum lacus, eu tincidunt eros lacus vitae libero.
.roboto-bold-italic
h3 Roboto Bold Italic
| Donec luctus ligula id augue blandit porta. Orci varius natoque
| penatibus et magnis dis parturient montes, nascetur ridiculus mus. Cras
| sem eros, iaculis pulvinar gravida vitae, interdum eu lacus. Praesent
| rutrum sem a dolor viverra aliquet. Vestibulum dictum tempus fringilla.
| Pellentesque eu eros elit. Integer fringilla ipsum sed hendrerit
| rhoncus.
.roboto-black
h3 Roboto Black
| In varius nibh elit. Nam nec pretium erat. Duis euismod mi vel massa
| scelerisque, ut tincidunt urna viverra. Praesent vel libero eros. Etiam
| a accumsan nulla. Nulla consequat venenatis risus quis accumsan. Etiam
| placerat pretium faucibus. Proin consequat in ante hendrerit lobortis.
| Interdum et malesuada fames ac ante ipsum primis in faucibus. Ut eget
| est tempus, aliquam enim quis, pellentesque erat. Nulla dapibus diam
| interdum vehicula dignissim. Donec orci velit, varius sed nisi semper,
| lobortis bibendum neque.
.roboto-black-italic
h3 Roboto Black Italic
| Proin felis velit, suscipit sit amet consequat id, consectetur et
| lectus. Donec porttitor sollicitudin lorem sed laoreet. Fusce rhoncus
| mi id nulla cursus mollis. Sed scelerisque et sem id eleifend. Maecenas
| quis nisi non diam tempor mattis at ut tortor. Ut auctor est odio, id
| scelerisque massa facilisis in. Suspendisse sollicitudin rutrum porta.
| Sed at purus eget lacus finibus sagittis. Sed nulla ligula, sagittis
| quis ipsum vel, finibus feugiat eros. Fusce non enim a lectus imperdiet
| auctor. Aliquam mattis molestie ante vel dignissim. Orci varius natoque
| penatibus et magnis dis parturient montes, nascetur ridiculus mus.
19 changes: 19 additions & 0 deletions app/fontTest/fontTest.module.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import angular from 'angular'

(function() {
'use strict'

var dependencies = [
'angular-jwt',
'ui.router',
'ngCookies',
'tc.services',
'tcUIComponents',
'angularSlideables',
'ngDialog',
'react'
]

angular.module('tc.fontTest', dependencies)

})()
53 changes: 53 additions & 0 deletions app/fontTest/fontTest.routes.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
import angular from 'angular'

(function() {
'use strict'

angular.module('tc.fontTest').config([
'$stateProvider',
routes
]).run(['$rootScope', '$state', function($rootScope, $state) {
$rootScope.$on('$stateChangeError', function(event, toState, toParams, fromState, fromParams, error) {
// if (toState.name.indexOf('sloog') > -1 && 400 <= error.status <= 500 ) {
//
// // unable to find a member with that username
// $state.go('404')
// }
})
$rootScope.$on('$stateChangeSuccess', function(event, toState, toParams, fromState, fromParams, error) {
if (toState.name !== 'font-test') {
// remove usersnap widget if not in listings page
var usersnapWidget = document.querySelectorAll('div[id*="_report_button"]')
if (usersnapWidget && usersnapWidget[0]) usersnapWidget[0].remove()
}
})
}])

function routes($stateProvider) {
var states = {
'font-test': {
parent: 'root',
url: '/font-test/',
resolve: {
userHandle: ['$stateParams', function($stateParams) {
return $stateParams.userHandle
}]
},
data: {
authRequired: false,
title: 'Font Test'
},
views: {
'container@': {
template: require('./fontTest')()
}
}
}
}

for (var name in states) {
var state = states[name]
$stateProvider.state(name, state)
}
}
})()
1 change: 1 addition & 0 deletions app/topcoder.module.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import { getCurrentUser, loadUser } from './services/userv3.service.js'
'tc.peer-review',
'tc.myDashboard',
'tc.listings',
'tc.fontTest',
'tc.mySRMs',
'tc.myChallenges',
'tc.profile',
Expand Down
115 changes: 115 additions & 0 deletions assets/css/_font-test.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
@import 'fonts';

.roboto-thin {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-weight: 100;
}

.roboto-thin-italic {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-weight: 100;
font-style: italic;
}

.roboto-light {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-weight: 300;
}

.roboto-light-italic {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-style: italic;
font-weight: 300;
}

.roboto-regular {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-weight: 400;
}

.roboto-regular-italic {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-style: italic;
font-weight: 400;
}

.roboto-medium {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-weight: 500;
}

.roboto-medium-italic {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-style: italic;
font-weight: 500;
}

.roboto-bold {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-weight: 700;
}

.roboto-bold-italic {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-style: italic;
font-weight: 700;
}

.roboto-black {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-weight: 900;
}

.roboto-black-italic {
h3 {
font-weight: bold;
margin: 24px 0 12px;
}
font-family: 'Roboto', Helvetica, Arial, sans-serif;
font-style: italic;
font-weight: 900;
}
41 changes: 41 additions & 0 deletions assets/css/_fonts.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
// FONT STACK
// --------------------------------------------------------------------------------------------
// Use the mixin to include fonts.

@mixin font-family($font-name, $font-weight, $font-style, $font-url, $font-file) {
@font-face {
font-family: '#{$font-name}';
src: url('#{$font-url}#{$font-file}.eot');
src: url('#{$font-url}#{$font-file}.eot?#iefix') format('embedded-opentype'), url('#{$font-url}#{$font-file}.woff') format('woff'), url('#{$font-url}#{$font-file}.ttf') format('truetype'), url('#{$font-url}#{$font-file}.svg##{$font-name}') format('svg');
font-weight: $font-weight;
font-style: $font-style;
}
}

// FONT WEIGHTS
// --------------------------------------------------------------------------------------------
// Use the numerical value instead of the weight name.

// 100 Thin (Hairline)
// 200 Extra Light (Ultra Light)
// 300 Light
// 400 Normal
// 500 Medium
// 600 Semi Bold (Demi Bold)
// 700 Bold
// 800 Extra Bold (Ultra Bold)
// 900 Black (Heavy)

// Roboto
@include font-family('Roboto', 900, normal, '../fonts/roboto/', 'roboto-black');
@include font-family('Roboto', 900, italic, '../fonts/roboto/', 'roboto-blackitalic');
@include font-family('Roboto', 700, normal, '../fonts/roboto/', 'roboto-bold');
@include font-family('Roboto', 700, italic, '../fonts/roboto/', 'roboto-bolditalic');
@include font-family('Roboto', 500, normal, '../fonts/roboto/', 'roboto-medium');
@include font-family('Roboto', 500, italic, '../fonts/roboto/', 'roboto-mediumitalic');
@include font-family('Roboto', 400, normal, '../fonts/roboto/', 'roboto-regular');
@include font-family('Roboto', 400, italic, '../fonts/roboto/', 'roboto-italic');
@include font-family('Roboto', 300, normal, '../fonts/roboto/', 'roboto-light');
@include font-family('Roboto', 300, italic, '../fonts/roboto/', 'roboto-lightitalic');
@include font-family('Roboto', 100, normal, '../fonts/roboto/', 'roboto-thin');
@include font-family('Roboto', 100, italic, '../fonts/roboto/', 'roboto-thinitalic');
2 changes: 2 additions & 0 deletions assets/css/topcoder.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
@import 'topcoder/tc-styles';
@import 'fonts';
@import 'font-test';
@include glyphicons-halflings;

@font-face {
Expand Down
Loading

0 comments on commit 4e6b596

Please sign in to comment.