Skip to content

Instantly share code, notes, and snippets.

@motion-work
motion-work / 0_reuse_code.js
Created June 3, 2016 21:17
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
import {Component, Alias, Inject, Init} from "../utils/Decorators"
@Alias('filterComp')
@Component({
selector: "filterComponent",
templateUrl: '/views/components/filter-component.html',
bind: {
config: '=',
changed: '=',
user: '='
import {Controller, State, Inject, Init} from "../utils/Decorators"
@State({
name: "member.home",
as: "homeCtrl",
url: "/",
templateUrl: "/views/home.html",
pageTitle: "Home"
})
export class HomeController {
@motion-work
motion-work / TransitionExpand.vue
Last active April 29, 2020 14:12
TransitionExpand.vue
<script>
export default {
name: `TransitionExpand`,
functional: true,
render(createElement, context) {
const data = {
props: {
name: `expand`,
},
on: {
<div style="z-index: 1000;" class="fixed right-4 bottom-4 shadow-md rounded-full bg-black w-12 h-12 flex justify-center items-center font-bold pt-1">
<span class="text-center text-white sm:hidden">less</span>
<span class="text-center text-white hidden sm:inline md:hidden">sm</span>
<span class="text-center text-white hidden md:inline lg:hidden">md</span>
<span class="text-center text-white hidden lg:inline xl:hidden">lg</span>
<span class="text-center text-white hidden xl:inline 2xl:hidden">xl</span>
<span class="text-center text-white hidden 2xl:inline 3xl:hidden">2xl</span>
<span class="text-center text-white hidden 3xl:inline 4xl:hidden">3xl</span>
<span class="text-center text-white hidden 4xl:inline">4xl</span>
</div>
<section class="hero-section">
<img class="hero-section__cover-image" src="https://res.cloudinary.com/delicious-cookie/image/upload/v1621503559/eldora/Sushi-Bowls_sst_1177552363_freigestellt-mit-Schatten_lowres_1_dtikls.png" alt="">
<div class="container">
<h1>Oase am See</h1>
<p>Willkommen im Quai Café. Willkommen in unserer Oase am See. Wir sind die Anlaufstelle für den perfekten Barista-Kaffee am Morgen, eine entspannte Mittagspause oder den Apéro nach Feierabend. Kommen Sie vorbei und probieren Sie unsere Sushi-Spezialitäten oder gönnen Sie sich ein Apéroplättchen mit einem kühlen Drink.</p>
</div>
</section>
<section class="morning-section">
@motion-work
motion-work / AnimatedContainer.vue
Created April 25, 2024 11:49
Nuxt 3 - AnimatedContainer using @hypernym/nuxt-gsap
<template>
<div ref="el" class="animated-container">
<slot />
</div>
</template>
<script setup>
const props = defineProps({
start: { type: String, default: null },
end: { type: String, default: null },