Socket
Socket
Sign inDemoInstall

nodebb-theme-oxide

Package Overview
Dependencies
Maintainers
1
Versions
147
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nodebb-theme-oxide - npm Package Compare versions

Comparing version 1.0.8 to 1.0.9

.jshintrc

4

lib/admin.js

@@ -12,6 +12,6 @@ 'use strict';

$('#save').on('click', function() {
Settings.save('oxide', $('.persona-settings'), function() {
Settings.save('oxide', $('.oxide-settings'), function() {
app.alert({
type: 'success',
alert_id: 'persona-saved',
alert_id: 'oxide-saved',
title: 'Settings Saved',

@@ -18,0 +18,0 @@ message: 'Oxide settings saved'

/* NProgress, (c) 2013, 2014 Rico Sta. Cruz - http://ricostacruz.com/nprogress
* @license MIT */
;(function(root, factory) {
; (function (root, factory) {

@@ -12,6 +12,6 @@ if (typeof exports === 'object') {

})(this, function() {
})(this, function () {
var NProgress = {};
NProgress.version = '0.1.6';
NProgress.version = '0.2.0';

@@ -24,4 +24,3 @@ var Settings = NProgress.settings = {

trickle: true,
trickleRate: 0.02,
trickleSpeed: 800,
trickleSpeed: 200,
showSpinner: true,

@@ -41,3 +40,3 @@ barSelector: '[role="bar"]',

*/
NProgress.configure = function(options) {
NProgress.configure = function (options) {
var key, value;

@@ -65,3 +64,3 @@ for (key in options) {

NProgress.set = function(n) {
NProgress.set = function (n) {
var started = NProgress.isStarted();

@@ -73,9 +72,9 @@

var progress = NProgress.render(!started),
bar = progress.querySelector(Settings.barSelector),
speed = Settings.speed,
ease = Settings.easing;
bar = progress.querySelector(Settings.barSelector),
speed = Settings.speed,
ease = Settings.easing;
progress.offsetWidth; /* Repaint */
queue(function(next) {
queue(function (next) {
// Set positionUsing if it hasn't already been set

@@ -89,14 +88,14 @@ if (Settings.positionUsing === '') Settings.positionUsing = NProgress.getPositioningCSS();

// Fade out
css(progress, {
transition: 'none',
opacity: 1
css(progress, {
transition: 'none',
opacity: 1
});
progress.offsetWidth; /* Repaint */
setTimeout(function() {
css(progress, {
transition: 'all ' + speed + 'ms linear',
opacity: 0
setTimeout(function () {
css(progress, {
transition: 'all ' + speed + 'ms linear',
opacity: 0
});
setTimeout(function() {
setTimeout(function () {
NProgress.remove();

@@ -114,3 +113,3 @@ next();

NProgress.isStarted = function() {
NProgress.isStarted = function () {
return typeof NProgress.status === 'number';

@@ -126,7 +125,7 @@ };

*/
NProgress.start = function() {
NProgress.start = function () {
if (!NProgress.status) NProgress.set(0);
var work = function() {
setTimeout(function() {
var work = function () {
setTimeout(function () {
if (!NProgress.status) return;

@@ -155,3 +154,3 @@ NProgress.trickle();

NProgress.done = function(force) {
NProgress.done = function (force) {
if (!force && !NProgress.status) return this;

@@ -166,3 +165,3 @@

NProgress.inc = function(amount) {
NProgress.inc = function (amount) {
var n = NProgress.status;

@@ -172,5 +171,11 @@

return NProgress.start();
} else if (n > 1) {
return;
} else {
if (typeof amount !== 'number') {
amount = (1 - n) * clamp(Math.random() * n, 0.1, 0.95);
if (n >= 0 && n < 0.2) { amount = 0.1; }
else if (n >= 0.2 && n < 0.5) { amount = 0.04; }
else if (n >= 0.5 && n < 0.8) { amount = 0.02; }
else if (n >= 0.8 && n < 0.99) { amount = 0.005; }
else { amount = 0; }
}

@@ -183,4 +188,4 @@

NProgress.trickle = function() {
return NProgress.inc(Math.random() * Settings.trickleRate);
NProgress.trickle = function () {
return NProgress.inc();
};

@@ -191,33 +196,33 @@

* increases the progress as the promises resolve.
*
*
* @param $promise jQUery Promise
*/
(function() {
(function () {
var initial = 0, current = 0;
NProgress.promise = function($promise) {
if (!$promise || $promise.state() == "resolved") {
NProgress.promise = function ($promise) {
if (!$promise || $promise.state() === "resolved") {
return this;
}
if (current == 0) {
if (current === 0) {
NProgress.start();
}
initial++;
current++;
$promise.always(function() {
$promise.always(function () {
current--;
if (current == 0) {
initial = 0;
NProgress.done();
if (current === 0) {
initial = 0;
NProgress.done();
} else {
NProgress.set((initial - current) / initial);
NProgress.set((initial - current) / initial);
}
});
return this;
};
})();

@@ -230,7 +235,7 @@

NProgress.render = function(fromStart) {
NProgress.render = function (fromStart) {
if (NProgress.isRendered()) return document.getElementById('nprogress');
addClass(document.documentElement, 'nprogress-busy');
var progress = document.createElement('div');

@@ -240,7 +245,7 @@ progress.id = 'nprogress';

var bar = progress.querySelector(Settings.barSelector),
perc = fromStart ? '-100' : toBarPerc(NProgress.status || 0),
parent = document.querySelector(Settings.parent),
spinner;
var bar = progress.querySelector(Settings.barSelector),
perc = fromStart ? '-100' : toBarPerc(NProgress.status || 0),
parent = document.querySelector(Settings.parent),
spinner;
css(bar, {

@@ -268,5 +273,5 @@ transition: 'all 0 linear',

NProgress.remove = function() {
NProgress.remove = function () {
removeClass(document.documentElement, 'nprogress-busy');
removeClass(document.querySelector(Settings.parent), 'nprogress-custom-parent')
removeClass(document.querySelector(Settings.parent), 'nprogress-custom-parent');
var progress = document.getElementById('nprogress');

@@ -280,3 +285,3 @@ progress && removeElement(progress);

NProgress.isRendered = function() {
NProgress.isRendered = function () {
return !!document.getElementById('nprogress');

@@ -289,3 +294,3 @@ };

NProgress.getPositioningCSS = function() {
NProgress.getPositioningCSS = function () {
// Sniff on document.body.style

@@ -296,5 +301,5 @@ var bodyStyle = document.body.style;

var vendorPrefix = ('WebkitTransform' in bodyStyle) ? 'Webkit' :
('MozTransform' in bodyStyle) ? 'Moz' :
('msTransform' in bodyStyle) ? 'ms' :
('OTransform' in bodyStyle) ? 'O' : '';
('MozTransform' in bodyStyle) ? 'Moz' :
('msTransform' in bodyStyle) ? 'ms' :
('OTransform' in bodyStyle) ? 'O' : '';

@@ -342,10 +347,10 @@ if (vendorPrefix + 'Perspective' in bodyStyle) {

if (Settings.positionUsing === 'translate3d') {
barCSS = { transform: 'translate3d('+toBarPerc(n)+'%,0,0)' };
barCSS = { transform: 'translate3d(' + toBarPerc(n) + '%,0,0)' };
} else if (Settings.positionUsing === 'translate') {
barCSS = { transform: 'translate('+toBarPerc(n)+'%,0)' };
barCSS = { transform: 'translate(' + toBarPerc(n) + '%,0)' };
} else {
barCSS = { 'margin-left': toBarPerc(n)+'%' };
barCSS = { 'margin-left': toBarPerc(n) + '%' };
}
barCSS.transition = 'all '+speed+'ms '+ease;
barCSS.transition = 'all ' + speed + 'ms ' + ease;

@@ -359,5 +364,5 @@ return barCSS;

var queue = (function() {
var queue = (function () {
var pending = [];
function next() {

@@ -370,3 +375,3 @@ var fn = pending.shift();

return function(fn) {
return function (fn) {
pending.push(fn);

@@ -378,15 +383,15 @@ if (pending.length == 1) next();

/**
* (Internal) Applies css properties to an element, similar to the jQuery
* (Internal) Applies css properties to an element, similar to the jQuery
* css method.
*
* While this helper does assist with vendor prefixed property names, it
* While this helper does assist with vendor prefixed property names, it
* does not perform any manipulation of values prior to setting styles.
*/
var css = (function() {
var cssPrefixes = [ 'Webkit', 'O', 'Moz', 'ms' ],
cssProps = {};
var css = (function () {
var cssPrefixes = ['Webkit', 'O', 'Moz', 'ms'],
cssProps = {};
function camelCase(string) {
return string.replace(/^-ms-/, 'ms-').replace(/-([\da-z])/gi, function(match, letter) {
return string.replace(/^-ms-/, 'ms-').replace(/-([\da-z])/gi, function (match, letter) {
return letter.toUpperCase();

@@ -401,4 +406,4 @@ });

var i = cssPrefixes.length,
capName = name.charAt(0).toUpperCase() + name.slice(1),
vendorName;
capName = name.charAt(0).toUpperCase() + name.slice(1),
vendorName;
while (i--) {

@@ -422,6 +427,6 @@ vendorName = cssPrefixes[i] + capName;

return function(element, properties) {
return function (element, properties) {
var args = arguments,
prop,
value;
prop,
value;

@@ -454,5 +459,5 @@ if (args.length == 2) {

var oldList = classList(element),
newList = oldList + name;
newList = oldList + name;
if (hasClass(oldList, name)) return;
if (hasClass(oldList, name)) return;

@@ -469,3 +474,3 @@ // Trim the opening space.

var oldList = classList(element),
newList;
newList;

@@ -482,4 +487,4 @@ if (!hasClass(element, name)) return;

/**
* (Internal) Gets a space separated list of the class names on the element.
* The list is wrapped with a single space on each end to facilitate finding
* (Internal) Gets a space separated list of the class names on the element.
* The list is wrapped with a single space on each end to facilitate finding
* matches within the list.

@@ -489,3 +494,3 @@ */

function classList(element) {
return (' ' + (element.className || '') + ' ').replace(/\s+/gi, ' ');
return (' ' + (element && element.className || '') + ' ').replace(/\s+/gi, ' ');
}

@@ -502,3 +507,2 @@

return NProgress;
});
});

@@ -5,7 +5,7 @@ "use strict";

define('oxide/quickreply', ['components'], function(components) {
define('oxide/quickreply', ['components'], function (components) {
var QuickReply = {};
QuickReply.init = function() {
QuickReply.init = function () {
var element = components.get('topic/quickreply/text');

@@ -17,15 +17,15 @@ var data = {

zIndex: 100,
listPosition: function(position) {
listPosition: function (position) {
this.$el.css(this._applyPlacement(position));
this.$el.css('position', 'absolute');
return this;
this.$el.css('position', 'absolute');
return this;
}
}
};
$(window).trigger('composer:autocomplete:init', data);
data.element.textcomplete(data.strategies, data.options);
$('.textcomplete-wrapper').css('height', '100%').find('textarea').css('height', '100%');
components.get('topic/quickreply/button').on('click', function(e) {
components.get('topic/quickreply/button').on('click', function (e) {
e.preventDefault();

@@ -39,6 +39,9 @@ var replyMsg = components.get('topic/quickreply/text').val();

socket.emit('posts.reply', replyData, function(err, data) {
socket.emit('posts.reply', replyData, function (err, data) {
if (err) {
app.alertError(err.message);
}
if (data && data.queued) {
app.alertSuccess(data.message);
}
components.get('topic/quickreply/text').val('');

@@ -48,4 +51,4 @@ });

};
return QuickReply;
});
});

@@ -12,6 +12,21 @@ "use strict";

configureNavbarHiding();
fixHeaderPadding();
$(window).on('resize', utils.debounce(configureNavbarHiding, 200));
$(window).on('resize', fixHeaderPadding);
function configureNavbarHiding () {
$(window).on('action:app.loggedIn', function () {
setupMobileMenu();
});
function fixHeaderPadding() {
var env = utils.findBootstrapEnvironment();
if (env === 'sm' || env === 'xs' || env === 'md') {
$('#panel').css('padding-top', $('#header-menu').outerHeight(true));
} else {
$('#panel').css('padding-top', $('#header-menu').outerHeight(true) - 70);
}
}
function configureNavbarHiding() {
var navbarEl = $(".navbar-fixed-top");

@@ -22,3 +37,3 @@ navbarEl.autoHidingNavbar('destroy');

var env = utils.findBootstrapEnvironment();
if (env === 'xs' || env ==='sm') {
if (env === 'xs' || env === 'sm') {
navbarEl.autoHidingNavbar({

@@ -46,3 +61,3 @@ showOnBottom: false,

function setupTaskbar() {
$(window).on('filter:taskbar.push', function(ev, data) {
$(window).on('filter:taskbar.push', function (ev, data) {
data.options.className = 'taskbar-' + data.module;

@@ -55,3 +70,3 @@

createChatIcon(data);
$(window).one('action:taskbar.pushed', function(ev, data) {
$(window).one('action:taskbar.pushed', function (ev, data) {
updateChatCount(data.element);

@@ -66,3 +81,3 @@ });

socket.on('event:chats.markedAsRead', function(data) {
socket.on('event:chats.markedAsRead', function (data) {
$('#taskbar [data-roomId="' + data.roomId + '"]')

@@ -74,3 +89,3 @@ .removeClass('new')

function createChatIcon(data) {
$.getJSON(config.relative_path + '/api/user/' + app.user.userslug + '/chats/' + data.options.roomId, function(chatObj) {
$.getJSON(config.relative_path + '/api/user/' + app.user.userslug + '/chats/' + data.options.roomId, function (chatObj) {
var el = $('#taskbar [data-uuid="' + data.uuid + '"] a');

@@ -86,3 +101,3 @@ el.parent('[data-uuid]').attr('data-roomId', data.options.roomId);

} else {
el .css('background-color', user['icon:bgColor'])
el.css('background-color', user['icon:bgColor'])
.text(user['icon:text'])

@@ -235,7 +250,5 @@ .addClass('user-icon');

$('#menu [data-section="navigation"] ul').html($('#main-nav').html() + ($('#search-menu').html() || '') + ($('#logged-out-menu').html() || ''));
$('#user-control-list').children().clone(true, true).appendTo($('#menu [data-section="profile"] ul'));
$('#menu [data-section="profile"] ul').find('[component="user/status"]').remove();
socket.on('event:user_status_change', function(data) {
socket.on('event:user_status_change', function (data) {
if (parseInt(data.uid, 10) === app.user.uid) {

@@ -279,13 +292,17 @@ app.updateUserStatus($('#menu [component="user/status"]'), data.status);

if (ajaxify.data.template['account/settings'] && !document.getElementById('oxide:menus:legacy-layout')) {
$('<div class="well checkbox"><label><input type="checkbox" id="oxide:menus:legacy-layout"/><strong>Switch which side each mobile menu is on</strong></label></div>')
.appendTo('#content .account > .row > div:first-child')
.find('input')
.prop('checked', Storage.getItem('oxide:menus:legacy-layout', 'true'))
.change(function (e) {
if (e.target.checked) {
Storage.setItem('oxide:menus:legacy-layout', 'true');
} else {
Storage.removeItem('oxide:menus:legacy-layout');
}
require(['translator'], function (translator) {
translator.translate('[[oxide:mobile-menu-side]]', function (translated) {
$('<div class="well checkbox"><label><input type="checkbox" id="oxide:menus:legacy-layout"/><strong>' + translated + '</strong></label></div>')
.appendTo('#content .account > .row > div:first-child')
.find('input')
.prop('checked', Storage.getItem('oxide:menus:legacy-layout', 'true'))
.change(function (e) {
if (e.target.checked) {
Storage.setItem('oxide:menus:legacy-layout', 'true');
} else {
Storage.removeItem('oxide:menus:legacy-layout');
}
});
});
})
}

@@ -300,3 +317,3 @@ }

function setupHoverCards() {
require(['components'], function(components) {
require(['components'], function (components) {
components.get('topic')

@@ -306,3 +323,3 @@ .on('click', '[component="user/picture"],[component="user/status"]', generateUserCard);

$(window).on('action:posts.loading', function(ev, data) {
$(window).on('action:posts.loading', function (ev, data) {
for (var i = 0, ii = data.posts.length; i < ii; i++) {

@@ -313,3 +330,3 @@ (ajaxify.data.topics || ajaxify.data.posts)[data.posts[i].index] = data.posts[i];

}
function generateUserCard(ev) {

@@ -316,0 +333,0 @@ var avatar = $(this),

'use strict';
var striptags = require('striptags');
var meta = module.parent.require('./meta');
var user = module.parent.require('./user');
var meta = require.main.require('./src/meta');
var user = require.main.require('./src/user');

@@ -116,2 +116,9 @@ var library = {};

} else {
data.templateData.loggedInUser = {
uid: 0,
username: '[[global:guest]]',
picture: user.getDefaultAvatar(),
'icon:text': '?',
'icon:bgColor': '#aaa',
};
callback(null, data);

@@ -118,0 +125,0 @@ }

{
"contributors": [
{
"name": "Sebastian Sycz",
"email": "youhosi99@gmail.com",
"url": "https://github.com/youhosi"
}
],
"description": "Oxide Theme",
"homepage": "https://oxidepolska.pl/",
"keywords": [
"nodebb",
"theme",
"forum",
"bootstrap",
"responsive",
"oxide"
],
"license": "MIT",
"main": "theme.less",
"name": "nodebb-theme-oxide",
"nbbpm": {
"compatibility": "^1.10.1"
},
"repository": {
"type": "git",
"url": "git+https://github.com/youhosi/nodebb-theme-oxide.git"
},
"version": "1.0.8"
"name": "nodebb-theme-oxide",
"description": "Oxide Theme for NodeBB",
"version": "1.0.9",
"homepage": "https://oxidepolska.pl/",
"license": "MIT",
"main": "theme.less",
"contributors": [
{
"name": "Sebastian Sycz",
"email": "sebastiansycz99@icloud.com",
"url": "https://github.com/youhosi"
}
],
"keywords": [
"nodebb",
"theme",
"forum",
"bootstrap",
"responsive",
"oxide"
],
"nbbpm": {
"compatibility": "^1.10.2"
},
"repository": {
"type": "git",
"url": "git+https://github.com/youhosi/nodebb-theme-oxide.git"
},
"bugs": {
"url": "https://github.com/youhosi/nodebb-theme-oxide/issues"
},
"dependencies": {
"pulling": "^2.0.0",
"striptags": "^3.1.1"
}
}

@@ -24,3 +24,4 @@ {

"lib/admin.js"
]
],
"languages": "languages"
}

@@ -7,3 +7,3 @@ # Oxide theme for NodeBB

![screenshot](https://raw.githubusercontent.com/youhosi/nodebb-theme-oxide/master/screenshot.png "Strona Główna Oxide Polska")
![screenshot](https://raw.githubusercontent.com/youhosi/nodebb-theme-oxide/master/screenshot2.png "Widok tematów")
![screenshot](https://raw.githubusercontent.com/youhosi/nodebb-theme-oxide/master/img/screenshot.png "Strona Główna Oxide Polska")
![screenshot](https://raw.githubusercontent.com/youhosi/nodebb-theme-oxide/master/img/screenshot2.png "Widok tematów")

@@ -6,3 +6,3 @@ {

"url": "https://github.com/youhosi/nodebb-theme-oxide",
"screenshot": "screenshot.png"
"screenshot": "./img/screenshot.png"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc