Skip to content

Instantly share code, notes, and snippets.

View ckvv's full-sized avatar
✌️
✌️

ckvv

✌️
✌️
View GitHub Profile
@ckvv
ckvv / RecycleScroller.vue
Created May 31, 2023 11:06
Vue虚拟列表实现
<script setup lang="ts">
import { computed, ref, unref } from 'vue';
const props = defineProps<{
items: any[]
itemSize: number
buffer: number
}>();
const wrapRef = ref();
@ckvv
ckvv / palette.scss
Last active September 28, 2022 08:08
scss automatically generates palettes
@function getColorPalette($colors) {
$levels: 1, 2, 3, 4, 5, 6, 7, 8, 9;
$interval: 15%;
$_colors: ();
@each $name, $color in $colors {
@debug $levels;
@each $level in $levels {
$_colors: map.deep-merge($_colors, (
#{$name}-#{$level}: color.scale($color, $lightness: $interval * (5 - $level)),
@ckvv
ckvv / lazada.py
Created August 8, 2022 12:55
lazada
# -*- coding: utf-8 -*-
'''
Created on 2018-03-21
@author: xuteng.xt
'''
import requests
import time
import hmac