Skip to content

Instantly share code, notes, and snippets.

@curtisj44
curtisj44 / match-iframe-height.js
Last active April 21, 2022 21:34
Responsive Test - Match iframe height to height of page contents
const setFrameHeight = (frameElement, index) => {
frameElement.style.height = 'unset';
const iframeElement = document.querySelectorAll('iframe')[index];
const targetHeight = `${ iframeElement.contentWindow.document.body.scrollHeight }px`;
iframeElement.style.height = targetHeight;
}
document.querySelectorAll('.frame').forEach((frameElement, index) => setFrameHeight(frameElement, index));
info:
title: test
version: 1.0.0
consumes:
- application/json
produces:
- application/json
swagger: '2.0'
securityDefinitions:
keystone:
@curtisj44
curtisj44 / CHANGELOG.md
Created July 27, 2021 16:32
Changelog Template
@curtisj44
curtisj44 / markdown.md
Last active March 5, 2021 20:00
Markdown Examples
@curtisj44
curtisj44 / bookmarking-bookmarklet.js
Last active May 11, 2023 17:58
Bookmarking Bookmarklet for Eleventy
// TODO: update this path to your repo on GitHub
const repo = "https://github.com/your-path/goes-here/new/master/posts";
const getToday = () => {
const today = new Date();
let dd = today.getDate();
let mm = today.getMonth() + 1;
const yyyy = today.getFullYear();
if (dd < 10) dd = `0${dd}`;
@curtisj44
curtisj44 / themer-dark-color-theme.json
Last active October 4, 2022 16:51
Custom color theme for Visual Studio Code
{
"_version": "1.27.2",
"_source": "https://gist.github.com/curtisj44/e72d8e1dfd950b69fc30eb5b31501795/edit",
"_colors": {
"black-background": "#2b2b2b",
"blue-light": "#87CEEB",
"blue-dark": "#2B91AF",
"gray-light (default text)": "#C0C0C0",
"grey-medium": "#808080",
@curtisj44
curtisj44 / maps.sass
Created November 10, 2018 19:26
Maps in Sass
// Maps in Sass
// ------------
// How it should be using `.scss` syntax
$mdc-typography-styles-button: (
font-size: 16px,
text-transform: none,
);
@curtisj44
curtisj44 / javascript-doc-format.js
Last active January 7, 2019 19:20
JavaScript documentation format
// Exports
// -------
// Verifies the current user has assignments
//
// Args:
// 1. `$$currentUser` - Immutable current_user object
//
// Example usage:
// `hasAssignments($$currentUser);`
@curtisj44
curtisj44 / font-stacks.css
Last active March 17, 2020 18:59
Miscellaneous font stacks
* {
/* System sans-serif */
/* ----------------- */
/* github.com - 20200211 */
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji'
/* tj.ie - 20200211 */
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sansserif
@curtisj44
curtisj44 / jirello.user.css
Last active June 9, 2016 21:18
A user style to make JIRA boards look a lot like Trello
/* v1.0.3 */
@namespace url(http://www.w3.org/1999/xhtml);
@-moz-document domain("atlassian.net") {
/* Backlog Ticket Preview */
#ghx-detail-view {
width: 0 !important;
}