Skip to content

Commit

Permalink
Merge pull request #183 from joelthorner/2.x
Browse files Browse the repository at this point in the history
2.3.13
  • Loading branch information
joelthorner authored Sep 2, 2019
2 parents 7da48ba + 76949a0 commit 4142b47
Show file tree
Hide file tree
Showing 23 changed files with 3,629 additions and 4,543 deletions.
2 changes: 1 addition & 1 deletion css/libs/huebee.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion css/libs/snackbar.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions css/main.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion css/main.css.map

Large diffs are not rendered by default.

39 changes: 39 additions & 0 deletions gulpfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
var gulp = require('gulp');

const libsJs = [
'node_modules/jquery/dist/jquery.min.js',
'node_modules/moment/min/moment.min.js',
'node_modules/bootstrap/dist/js/bootstrap.min.js',
'node_modules/hotkeys-js/dist/hotkeys.min.js',
'node_modules/js-cookie/src/js.cookie.js',
'node_modules/huebee/dist/huebee.pkgd.min.js',
'node_modules/popper.js/dist/umd/popper.min.js',
'node_modules/node-snackbar/dist/snackbar.min.js',
'node_modules/sweetalert2/dist/sweetalert2.all.min.js',
]

const scssBootstrap = [
'node_modules/bootstrap/scss/**/*.scss'
]

const libsCss = [
'node_modules/huebee/dist/huebee.min.css',
'node_modules/node-snackbar/dist/snackbar.min.css',
]

gulp.task('default', function () {
libsJs.forEach(libJs => {
gulp.src(libJs).pipe(gulp.dest('js/libs'));
});
libsCss.forEach(libCss => {
gulp.src(libCss).pipe(gulp.dest('css/libs'));
});
scssBootstrap.forEach(libScss => {
gulp.src(libScss).pipe(gulp.dest('scss/bootstrap'));
});
});

// execute for update dependencies:
// $ npm update
// $ gulp
// Execute any scss compiler (pending to do in gulp)
14 changes: 9 additions & 5 deletions js/background.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ chrome.runtime.onMessage.addListener(
switch (request.directive) {
case 'testing-signup':
executeScripts(null, [
{ file: 'js/libs/moment.js' },
{ file: 'js/libs/moment.min.js' },
{ file: 'js/actions/testing-signup.js' }
])
break;
Expand Down Expand Up @@ -87,7 +87,7 @@ chrome.runtime.onInstalled.addListener(function (details) {
// TicketConsume system
function openTicketConsumeTab() {
chrome.tabs.create({
url: 'http://192.168.110.109:12853/zdreports/rtm.cfm/?TicketConsume=true',
url: 'http://192.168.110.109:12853/zdreports/rtm.cfm?TicketConsume=true',
// url: 'https://joelthorner.github.io/temp/?TicketConsume=true',
active: false,
// index: 0,
Expand All @@ -103,7 +103,7 @@ chrome.runtime.onMessage.addListener(function (message, sender) {
tabs.forEach(tab => {
chrome.tabs.sendMessage(tab.id, { data: message.data });
chrome.tabs.query({
url: '*://zdreports/rtm.cfm/?TicketConsume=true'
url: '*://zdreports/rtm.cfm?TicketConsume=true'
// url: '*://joelthorner.github.io/temp/?TicketConsume=true'
}, function (tabs) {
tabs.forEach(tab => { chrome.tabs.remove(tab.id) });
Expand All @@ -115,7 +115,11 @@ chrome.runtime.onMessage.addListener(function (message, sender) {
chrome.tabs.onActivated.addListener(function (activeInfo) {
chrome.tabs.get(activeInfo.tabId, function (tab){
if (tab.url.includes("tlgcommercehelp.zendesk.com")) {
openTicketConsumeTab()
chrome.storage.sync.get({ optZenTicketConsume: false }, function (result) {
if (result.optZenTicketConsume) {
openTicketConsumeTab()
}
});
}
})
});
});
4 changes: 2 additions & 2 deletions js/libs/hotkeys.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 4142b47

Please sign in to comment.