Skip to content

Instantly share code, notes, and snippets.

View ariona's full-sized avatar
🏠
Working from home

Rian Ariona ariona

🏠
Working from home
View GitHub Profile
@ariona
ariona / README.MD
Last active December 14, 2017 07:43
Formatting seconds times to HH:MM:SS

Convert Seconds time format into HH:MM:SS.

If the seconds is less than an hour then the format returned will be MM:SS

@ariona
ariona / readme.md
Last active October 5, 2022 13:41
Developing React-native App on MIUI

If you are developing React native based Android App and using XIAOMI/MIUI Device, this tips might help you to get rid some headache when debugging the app

Enabling Developer Menu

To enable Developer Menu, you need to tag 7 times on MIUI Version under About Phone Setting menu instead of Build Number. The Developer Menu can be found on Additional Settings

Can't Install Debug APK? "...Failed to establish session"?

  1. enable developer mode - In your phone, go to Settings, About phone and click on MIUI version 7 times. You’ll see a pop up which says you are a developer now.
  2. Go back to Settings, Additional settings, Developer options and enable USB Debugging.
  3. Connect your phone to your PC/Mac and on the phone authorize your computer
@ariona
ariona / admin.js
Created March 28, 2017 12:06
autosaving post meta
jQuery('button').on('click', function(){
...
wp.autosave.server.triggerSave();
...
})
@ariona
ariona / style.css
Created January 9, 2017 08:02
Element Flickr CSS Animation
@keyframes link-shudder
{
0% { margin-bottom:0;}
1% { transform: translate(0px,0px); }
2% { transform: translate(-6px,-3px); }
3% { transform: translate(0px,0px); }
10% { filter:blur(0px);}
15% { filter:blur(3px);}
20% { filter:blur(0px);}
27% { transform: translate(0px,0px); }
@ariona
ariona / index.css
Created December 14, 2016 08:32
Customizable svg background image
/* Use this as inline css */
el{
background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="14" viewBox="0 0 29 14" width="29"><path fill="#d1d1d1" d="M9.37727 3.625l5.08154 6.93523L19.54036 3.625"/></svg>') center right repeat-x;
}
@ariona
ariona / fill.css
Created December 5, 2016 09:57
svg text background
.site-hero .intro-block svg .img-layer {
fill: url(#p-img);
}
@ariona
ariona / Preferences.sublime-settings
Last active September 27, 2016 07:28
Exclude node_modules from Sublime search
{
"folder_exclude_patterns": [".svn", ".git", ".hg", "CVS", "node_modules"]
}
@ariona
ariona / index.jade
Created September 1, 2016 10:14
PGoPqV
button.fetch Fetch
ul.items
input.purchase-code(type="text")
button.verify Verify purchase code
@ariona
ariona / index.jade
Created August 5, 2016 09:05
xOyPaa
.builder
#elements
.element(data-element-name="logo")
.element-icon
i.fa.fa-adn
.element-name Logo
.element-controls
button.delete-element
i.fa.fa-trash-o
button.options
@ariona
ariona / _readme.md
Created June 14, 2016 02:19
Hiding Screen Reader Text