A tweet-sized debugger for visualizing your CSS layouts. Outlines every DOM element on your page a random (valid) CSS hex color.
One-line version to paste in your DevTools
Use $$ if your browser aliases it:
~ 108 byte version
| <?xml version="1.0" encoding="utf-8"?> | |
| <resources> | |
| <color name="material_red50">#ffffebee</color> | |
| <color name="material_red100">#ffffcdd2</color> | |
| <color name="material_red200">#ffef9a9a</color> | |
| <color name="material_red300">#ffe57373</color> | |
| <color name="material_red400">#ffef5350</color> | |
| <color name="material_red500">#fff44336</color> | |
| <color name="material_red600">#ffe53935</color> | |
| <color name="material_red700">#ffd32f2f</color> |
| { | |
| "env": { | |
| "browser": true, | |
| "node": true, | |
| "es6": true | |
| }, | |
| "plugins": ["react"], | |
| "ecmaFeatures": { |
| /* bling.js */ | |
| window.$ = document.querySelector.bind(document); | |
| window.$$ = document.querySelectorAll.bind(document); | |
| Node.prototype.on = window.on = function(name, fn) { this.addEventListener(name, fn); }; | |
| NodeList.prototype.__proto__ = Array.prototype; | |
| NodeList.prototype.on = function(name, fn) { this.forEach((elem) => elem.on(name, fn)); }; |
| public class ThingsAdapter extends RecyclerView.Adapter<ThingsAdapter.ViewHolder> { | |
| private ParseQueryAdapter<ParseObject> parseAdapter; | |
| private ViewGroup parseParent; | |
| private ThingsAdapter thingsAdapter = this; | |
| public ThingsAdapter(Context context, ViewGroup parentIn) { | |
| parseParent = parentIn; |
| import android.support.v7.widget.LinearLayoutManager; | |
| import android.support.v7.widget.RecyclerView; | |
| public abstract class EndlessRecyclerOnScrollListener extends RecyclerView.OnScrollListener { | |
| public static String TAG = EndlessRecyclerOnScrollListener.class.getSimpleName(); | |
| private int previousTotal = 0; // The total number of items in the dataset after the last load | |
| private boolean loading = true; // True if we are still waiting for the last set of data to load. | |
| private int visibleThreshold = 5; // The minimum amount of items to have below your current scroll position before loading more. | |
| int firstVisibleItem, visibleItemCount, totalItemCount; |
| <!doctype html> | |
| <html> | |
| <head> | |
| <!-- Web Component Polyfill for old browsers --> | |
| <script src="https://www.polymer-project.org/platform.js"></script> | |
| <!-- Release candidate of next React --> | |
| <script src="http://fb.me/react-with-addons-0.12.0-rc1.js"></script> | |
| <script src="http://fb.me/JSXTransformer-0.12.0-rc1.js"></script> | |
| <!-- Import a web component --> |
| <!-- You can change the parent around to whatever you normally use --> | |
| <style name="DebugColors" parent="Theme.AppCompat"> | |
| <!-- System colors --> | |
| <item name="android:windowBackground">@color/__debugWindowBackground</item> | |
| <item name="android:colorPressedHighlight">#FF4400</item> | |
| <item name="android:colorLongPressedHighlight">#FF0044</item> | |
| <item name="android:colorFocusedHighlight">#44FF00</item> | |
| <item name="android:colorActivatedHighlight">#00FF44</item> |
| /* | |
| * Copyright (C) 2014 skyfish.jy@gmail.com | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, software |
| <?xml version="1.0" encoding="utf-8"?> | |
| <resources> | |
| <color name="red_50">#fde0dc</color> | |
| <color name="red_100">#f9bdbb</color> | |
| <color name="red_200">#f69988</color> | |
| <color name="red_300">#f36c60</color> | |
| <color name="red_400">#e84e40</color> | |
| <color name="red_500">#e51c23</color> | |
| <color name="red_600">#dd191d</color> | |
| <color name="red_700">#d01716</color> |