Skip to content

Instantly share code, notes, and snippets.

View stepanselyuk's full-sized avatar

Stepan Seliuk stepanselyuk

View GitHub Profile
.dropdown-submenu {
position: relative;
& > .dropdown-menu {
top: 0;
left: 100%;
margin-top: -6px;
margin-left: -1px;
-webkit-border-radius: 0 6px 6px 6px;
-moz-border-radius: 0 6px 6px 6px;
@stepanselyuk
stepanselyuk / myapp.tt.js
Created September 1, 2014 13:13
Yii::t javascript version
/**
* Created by PhpStorm.
* Author: Stepan Seliuk <[email protected]>
* Date: 30/08/14
* Time: 20:20
*/
if ( typeof window.MyApp === 'undefined' ) window.MyApp = {};
MyApp.ttLib = {
@stepanselyuk
stepanselyuk / functions.common.js
Created September 1, 2014 13:16
isEmptyObject and matchRecursiveRegExp
MyApp.CommonFunctionsModule.isEmptyObject = function ( obj ) {
var hasOwnProperty = Object.prototype.hasOwnProperty;
// null and undefined are "empty"
if ( obj == null ) return true;
// Assume if it has a length property with a non-zero value
// that that property is correct.
if ( obj.length > 0 ) return false;
@stepanselyuk
stepanselyuk / TwitterCldrAsset.php
Created September 1, 2014 13:17
TwitterCldrAsset Yii2
<?php
/**
* Created by PhpStorm.
* Author: Stepan Seliuk <[email protected]>
* Date: 31/08/14
* Time: 19:45
*/
namespace app\assets;
@stepanselyuk
stepanselyuk / JsTranslationsController.php
Created September 1, 2014 13:19
Collect strings for translation from *.js files Generate JSON resources
<?php
/**
* Created by PhpStorm.
* Author: Stepan Seliuk <[email protected]>
* Date: 30/08/14
* Time: 20:29
*/
namespace app\commands\system;
@stepanselyuk
stepanselyuk / JavaScriptMessages.php
Created September 1, 2014 13:21
Component for generating JS-files for include in page
<?php
/**
* Created by PhpStorm.
* Author: Stepan Seliuk <[email protected]>
* Date: 30/08/14
* Time: 22:33
*/
namespace app\components\i18n;
@stepanselyuk
stepanselyuk / en-US.messages.js
Created September 1, 2014 13:26
Resources JSON and JS
if ( typeof window.MyApp === 'undefined' ) window.MyApp = {};
MyApp.ttData = {"params":{"lang":"en-US","source_lang":"ru-RU","currency":"EUR"},"messages":{"\u041d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043e\u0434\u043d\u0443 \u0441\u0442\u0440\u043e\u043a\u0443.":"You should select a one row.","\u041d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c {a} \u0441\u0442\u0440\u043e\u043a\u0443.":"You should select {a} row."}};
@stepanselyuk
stepanselyuk / AppThreadTrait.php
Created September 1, 2014 13:44
AppThread Trait
<?php
/**
* Created by PhpStorm.
* Author: Stepan Seliuk <[email protected]>
* Date: 01/06/14
* Time: 15:46
*/
namespace app\components\traits;
@stepanselyuk
stepanselyuk / ConsoleAppHelper.php
Created January 19, 2015 20:28
ConsoleAppHelper
<?php
/**
* Created by PhpStorm.
* Author: Stepan Seliuk <[email protected]>
* Date: 04/09/14
* Time: 22:22
*/
namespace app\components;
@stepanselyuk
stepanselyuk / API Vevo
Last active August 29, 2015 14:22 — forked from NTag/API Vevo
239.255.255.250
http://9cf9.v.fwmrm.net
http://api.twitter.com/1.1/
http://api.twitter.com/oauth/access_token
http://api.twitter.com/oauth/authenticate
http://api.twitter.com/oauth/authorize
http://api.twitter.com/oauth/request_token
http://api.vevo.com/mobile/v1/
http://api.vevo.com/mobile/v1/artist/
http://api.vevo.com/mobile/v1/artist/list.json?