Skip to content
This repository has been archived by the owner on Jul 24, 2023. It is now read-only.

Commit

Permalink
style(css,js,json,scss): apply prettier auto formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristianMurphy committed Oct 31, 2017
1 parent 4ce9c30 commit 0042254
Show file tree
Hide file tree
Showing 12 changed files with 309 additions and 271 deletions.
17 changes: 9 additions & 8 deletions docs/assets/css/style.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
---
---

@import "{{ site.theme }}";
@import '{{ site.theme }}';

.wrapper {
width: auto;
Expand All @@ -27,7 +24,7 @@ header {
}
}
a.button {
box-shadow: 0 2px 5px 0 rgba(0,0,0,.26);
box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26);
background: #39c;
color: #fff;
display: inline-block;
Expand All @@ -51,8 +48,10 @@ header {
font-weight: 500;
text-decoration: none;
overflow: hidden;
-webkit-transition: box-shadow .4s cubic-bezier(.25,.8,.25,1),background-color .4s cubic-bezier(.25,.8,.25,1);
transition: box-shadow .4s cubic-bezier(.25,.8,.25,1),background-color .4s cubic-bezier(.25,.8,.25,1);
-webkit-transition: box-shadow 0.4s cubic-bezier(0.25, 0.8, 0.25, 1),
background-color 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
transition: box-shadow 0.4s cubic-bezier(0.25, 0.8, 0.25, 1),
background-color 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
&:hover {
background: #069;
}
Expand Down Expand Up @@ -120,7 +119,9 @@ footer {
body {
margin: 0;
padding: 40px 40px 40px 0;
header, section, footer {
header,
section,
footer {
padding-left: 40px;
}
}
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"build:lint-js":
"eslint --ext js --ext json --ext md . --ignore-path .gitignore",
"build": "npm run build:pre && npm run build:test && npm run build:lint-js",
"format": "prettier-eslint --write \"**/*.{js,json,css,scss}\"",
"test": "npm run build:pre && npm run build:test",
"lint-js": "npm run build:pre && npm run build:lint-js",
"dev": "npm run build:pre && mvn jetty:run",
Expand Down
2 changes: 1 addition & 1 deletion src/main/webapp/js/config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* eslint-disable no-unused-vars */
var config = {
'gaID': '',
gaID: '',
};
55 changes: 27 additions & 28 deletions src/main/webapp/js/override.js
Original file line number Diff line number Diff line change
@@ -1,32 +1,31 @@
define(['angular'], function(angular) {
// see https://uw-madison-doit.github.io/uw-frame/configuration.html for howto
return angular.module('override', [])
.constant('OVERRIDE', {
'APP_FLAGS': {
'defaultTheme': 'uwMadison',
'showSearch': false,
'isWeb': false,
'loginOnLoad': false,
return angular.module('override', []).constant('OVERRIDE', {
APP_FLAGS: {
defaultTheme: 'uwMadison',
showSearch: false,
isWeb: false,
loginOnLoad: false,
},
NAMES: {
title: 'Widget Creator',
fname: 'widget-creator',
},
SERVICE_LOC: {
kvURL: null,
groupURL: 'staticFeeds/groups.json',
sessionInfo: 'staticFeeds/guest-session.json',
shibbolethSessionURL: 'staticFeeds/Shibboleth.sso/Session.json',
templates: 'json/starter-templates',
widgetApi: {
// For local testing, change to 'staticFeeds/'
entry: 'data:application/json;base64,',
entrySuffix: '',
entries: null,
},
'NAMES': {
'title': 'Widget Creator',
'fname': 'widget-creator',
},
'SERVICE_LOC': {
'kvURL': null,
'groupURL': 'staticFeeds/groups.json',
'sessionInfo': 'staticFeeds/guest-session.json',
'shibbolethSessionURL': 'staticFeeds/Shibboleth.sso/Session.json',
'templates': 'json/starter-templates',
'widgetApi': {
// For local testing, change to 'staticFeeds/'
'entry': 'data:application/json;base64,',
'entrySuffix': '',
'entries': null,
},
},
'MISC_URLS': {
'rootURL': 'https://my.wisc.edu',
},
});
},
MISC_URLS: {
rootURL: 'https://my.wisc.edu',
},
});
});
7 changes: 4 additions & 3 deletions src/main/webapp/json/starter-templates.json
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,8 @@
"widgetType": "time-sensitive-content",
"title": "Time Sensitive Content",
"mdIcon": "widgets",
"description": "A widget for displaying content before, during, and after a specified period of time",
"description":
"A widget for displaying content before, during, and after a specified period of time",
"widgetConfig": {
"callsToAction": [
{
Expand All @@ -183,8 +184,8 @@
"daysLeftMessage": "to make it happen.",
"lastDayMessage": "Today is the last day it could happen.",
"actionButton": {
"url": "//www.example.com",
"label": "Do it to it"
"url": "//www.example.com",
"label": "Do it to it"
},
"learnMoreUrl": "//www.example.com",
"feedbackUrl": "//www.example.com"
Expand Down
44 changes: 26 additions & 18 deletions src/main/webapp/my-app/main.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
define([
define(
[
'angular',
'require',
'./view-home/routes', // add all the paths to your routes here
Expand All @@ -13,15 +14,18 @@ define([
'./view-home/controllers', // add all your paths to your other js files here
'./view-home/directives',
'./view-home/services',
], function(
],
function(
angular,
require,
homeRoutes,
settingsRoutes,
aboutRoute,
mainRoutes
) { // notice each route file is now an object
return angular.module('my-app', [
) {
// notice each route file is now an object
return angular
.module('my-app', [
'app-config',
'my-app.view-home.controllers', // add in your modules here
'my-app.view-home.directives',
Expand All @@ -30,17 +34,21 @@ define([
'ngSanitize',
'ngStorage',
'portal',
])
.config(['$routeProvider', '$locationProvider',
function($routeProvider, $locationProvider) {
$locationProvider.html5Mode(true);
// IMPORTANT: Keep theses paths in sync with web.xml for html5mode
$routeProvider
.when('/home', homeRoutes.home)
.when('/settings', settingsRoutes.betaSettings)
.when('/user-settings', settingsRoutes.userSettings)
.when('/about', aboutRoute)
.when('/access-denied', mainRoutes.accessDenied)
.otherwise({'redirectTo': '/home'});
}]);
});
])
.config([
'$routeProvider',
'$locationProvider',
function($routeProvider, $locationProvider) {
$locationProvider.html5Mode(true);
// IMPORTANT: Keep theses paths in sync with web.xml for html5mode
$routeProvider
.when('/home', homeRoutes.home)
.when('/settings', settingsRoutes.betaSettings)
.when('/user-settings', settingsRoutes.userSettings)
.when('/about', aboutRoute)
.when('/access-denied', mainRoutes.accessDenied)
.otherwise({redirectTo: '/home'});
},
]);
}
);
44 changes: 23 additions & 21 deletions src/main/webapp/my-app/my-app.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,26 @@
}

.widget-creator .portlet-body {
padding: 10px;
padding: 10px;
}

.widget-creator .container__select-template {
padding-bottom: 20px;
padding-bottom: 20px;
}

.widget-creator preview-widget {
width: 300px;
width: 300px;
}

.widget-creator .help-notes p {
color: #999;
font-size: 12px;
margin-bottom: 0;
color: #999;
font-size: 12px;
margin-bottom: 0;
}

.widget-creator textarea {
padding: 10px 14px;
overflow-y: scroll;
padding: 10px 14px;
overflow-y: scroll;
}

.widget-creator .hint {
Expand All @@ -41,26 +41,28 @@
}

.widget-creator ::-webkit-input-placeholder {
color: @grayscale6;
font-size: 12px;
color: @grayscale6;
font-size: 12px;
}

.widget-creator :-moz-placeholder { /* Firefox 18- */
color: @grayscale6;
font-size: 12px;
.widget-creator :-moz-placeholder {
/* Firefox 18- */
color: @grayscale6;
font-size: 12px;
}

.widget-creator ::-moz-placeholder { /* Firefox 19+ */
color: @grayscale6;
font-size: 12px;
.widget-creator ::-moz-placeholder {
/* Firefox 19+ */
color: @grayscale6;
font-size: 12px;
}

.widget-creator :-ms-input-placeholder {
color: @grayscale6;
font-size: 12px;
.widget-creator :-ms-input-placeholder {
color: @grayscale6;
font-size: 12px;
}

.widget-middle {
width: 315px;
margin: auto;
width: 315px;
margin: auto;
}
Loading

0 comments on commit 0042254

Please sign in to comment.