Skip to content

Commit

Permalink
Hides capacity column and filter Refs #10
Browse files Browse the repository at this point in the history
  • Loading branch information
Christopher Green committed Jun 21, 2017
1 parent 0551f90 commit 9fe8e8b
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 11 deletions.
10 changes: 7 additions & 3 deletions app/lib/hide-capacity.es6
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
// Hides the 'Capacity column'
export function hideCapacity () {

// Hide the 'Capacity column'
document.querySelectorAll('.fc-resource-area.fc-widget-header .fc-content .fc-widget-header')[1].remove()

document.querySelectorAll('.fc-resource-area.fc-widget-header .fc-content colgroup col')[1].remove()

let rows = document.querySelectorAll('.fc-resource-area.fc-widget-content .fc-content tr')

for (let i = 0; i < rows.length; i++) {
rows[i].children[1].remove()
if (rows[i].children.length > 1) {
rows[i].children[1].remove()
}
}

document.querySelectorAll('.fc-resource-area.fc-widget-content .fc-content colgroup col')[1].remove()

// Hide the 'Capacity' filter
document.querySelectorAll('#s-lc-eq-navform .form-inline .form-group')[2].remove()
}
2 changes: 1 addition & 1 deletion app/main.es6
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {hideTinyFooter} from './lib/hide-tiny-footer'
import {showHeader, showFooter} from './lib/template'

document.addEventListener('DOMContentLoaded', () => {
// hideCapacity()
hideCapacity()
// hideRoomInfo()

showHeader()
Expand Down
16 changes: 10 additions & 6 deletions dist/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ return /******/ (function(modules) { // webpackBootstrap
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "https://bexidsojed.localtunnel.me/";
/******/ __webpack_require__.p = "https://xbbziloico.localtunnel.me/";
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = 7);
Expand All @@ -93,21 +93,25 @@ function hideBreadcrumbs () {
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export hideCapacity */
// Hides the 'Capacity column'
/* harmony export (immutable) */ __webpack_exports__["a"] = hideCapacity;
function hideCapacity () {

// Hide the 'Capacity column'
document.querySelectorAll('.fc-resource-area.fc-widget-header .fc-content .fc-widget-header')[1].remove()

document.querySelectorAll('.fc-resource-area.fc-widget-header .fc-content colgroup col')[1].remove()

let rows = document.querySelectorAll('.fc-resource-area.fc-widget-content .fc-content tr')

for (let i = 0; i < rows.length; i++) {
rows[i].children[1].remove()
if (rows[i].children.length > 1) {
rows[i].children[1].remove()
}
}

document.querySelectorAll('.fc-resource-area.fc-widget-content .fc-content colgroup col')[1].remove()

// Hide the 'Capacity' filter
document.querySelectorAll('#s-lc-eq-navform .form-inline .form-group')[2].remove()
}


Expand Down Expand Up @@ -17350,7 +17354,7 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true });


document.addEventListener('DOMContentLoaded', () => {
// hideCapacity()
__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_2__lib_hide_capacity__["a" /* hideCapacity */])()
// hideRoomInfo()

__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_6__lib_template__["a" /* showHeader */])()
Expand Down
2 changes: 1 addition & 1 deletion dist/bundle.js.map

Large diffs are not rendered by default.

0 comments on commit 9fe8e8b

Please sign in to comment.