This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"workbench.settings.openDefaultSettings": false, | |
"workbench.settings.openDefaultKeybindings": true, | |
"editor.fontFamily": "menlo, dejavu sans code hinted, hackmen, jetbrains mono, fira code, consolas, hasklig, iosevka ss04, courier new", | |
"editor.fontLigatures": true, | |
"window.zoomLevel": -1, | |
"editor.fontSize": 17, | |
"editor.lineHeight": 26, | |
"terminal.integrated.fontSize": 17, | |
"editor.letterSpacing": -0.5, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.fixed-ratio-block { | |
position: relative; | |
} | |
.fixed-ratio-block:before { | |
content: ''; | |
display: block; | |
padding-top: 80%; | |
} | |
.fixed-ratio-block__content { | |
position: absolute; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main exposing (main) | |
import Browser | |
import Html exposing (Html, button, div, text, input, label, button) | |
import Html.Attributes exposing (type_, class, value, name, checked) | |
import Html.Events exposing (onClick) | |
type alias Model = | |
{ count : Int, fields: List Field } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"workbench.colorCustomizations": { | |
"[Visual Studio Dark]": { | |
// Emerald 028a0f | |
// Pistachio b2d3c2 | |
// Fern 5dbb63 | |
// Parakeet 03c04a | |
"editor.background": "#5dbb63", | |
"editor.foreground": "#fffc", | |
"editorIndentGuide.background": "#0001", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function onVisible(el, once=true) { | |
return new Promise((done, fail) => { | |
new IntersectionObserver((entries, observer) => { | |
entries.forEach(entry => { | |
if (entry.intersectionRatio > 0) { | |
done(el, observer, entry) | |
if (once) {observer.disconnect()} | |
} | |
}) | |
}).observe(el) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
;window.addEventListener('load', () => { | |
/// пример <span data-count-from='0' data-count-to='8000000' data-count-duration='2000'>8.000.000</span> | |
function onceVisible(el, callback) { | |
new IntersectionObserver((entries, observer) => { | |
entries.forEach(entry => { | |
if (entry.isIntersecting) { | |
callback(el, entry, observer) | |
observer.disconnect() | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main exposing (main) | |
import Browser | |
import Browser.Events as Events | |
import Browser.Dom as Dom | |
import Html exposing (Html, button, div, text) | |
import Html.Attributes exposing (class, style, id) | |
import Html.Events exposing (onClick) | |
import Html.Events.Extra.Mouse as Mouse | |
import Json.Decode as D |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.db.models import Sum | |
from .models import Item | |
# for django < 1.8 | |
group_sums = Item.objects.filter(deleted=None).values('user').annotate(sum=Sum('price', field='price*quantity')) | |
# group_sums :: [{'user': 123, 'sum': 9999}] | |
# values + annotate => GROUP BY in sql |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"workbench.colorCustomizations": { | |
"[Default Light+]": { | |
"panel.background": "#eee", | |
"terminal.background": "#fff", | |
"editorPane.background": "#eee", | |
"editorGutter.background": "#eee", | |
"editorGroupHeader.noTabsBackground": "#eee", | |
"list.inactiveSelectionBackground": "#cde", | |
"sideBar.border": "#ccc", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"workbench.colorCustomizations": { | |
"[Eiffel]": { | |
"editorGroupHeader.noTabsBackground": "#eee", | |
}, | |
}, | |
"editor.tokenColorCustomizations": { | |
"[Eiffel]": {"textMateRules": [ | |
{"settings":{"foreground":"#000"},"scope":[ | |
"invalid.illegal.unrecognized-tag.html", |
OlderNewer