add gist loading page

format code
This commit is contained in:
DefectingCat
2023-08-14 13:36:15 +08:00
parent d6447c6a8e
commit 32d8d48514
44 changed files with 142 additions and 107 deletions

View File

@ -28,7 +28,7 @@ const CopyButton = ({ onCopy: onClick, className }: CopyButtonProps) => {
'transition-opacity dark:border-gray-700',
'duration-300',
className,
styles.btn
styles.btn,
)}
onClick={handleClick}
>
@ -36,14 +36,14 @@ const CopyButton = ({ onCopy: onClick, className }: CopyButtonProps) => {
className={clsx(
'relative w-5 h-5 text-gray-400 child',
'transition-all duration-300',
styles.child
styles.child,
)}
>
<svg
className={clsx(
'absolute top-0 left-0 fill-current',
'opacity-100 transition-all duration-300',
copied && styles['on_copy']
copied && styles['on_copy'],
)}
viewBox="0 0 24 24"
>
@ -54,7 +54,7 @@ const CopyButton = ({ onCopy: onClick, className }: CopyButtonProps) => {
'absolute top-0 left-0 fill-green-400',
'scale-[0.33] transition-all duration-300',
'opacity-0',
copied && styles['on_ok']
copied && styles['on_ok'],
)}
viewBox="0 0 24 24"
>

View File

@ -37,7 +37,7 @@ const PostToc = ({ toc, tocLength }: Props) => {
'select-none cursor-pointer',
'rounded-lg transition-all',
'duration-500 overflow-hidden',
'my-4 text-xl'
'my-4 text-xl',
)}
style={{
maxHeight: show ? (tocLength ?? 0) * 50 + 60 : 60,
@ -52,7 +52,7 @@ const PostToc = ({ toc, tocLength }: Props) => {
<FiChevronDown
className={clsx(
show && 'rotate-180',
'transition-all duration-500'
'transition-all duration-500',
)}
/>
</div>