import "./styles/style.scss";
import "./styles/font-hack.scss";
import "./styles/font-pixel.scss";

import Alpine from 'alpinejs'
import {upvote} from './alpine/upvote'
import {themeMode} from './alpine/theme-mode'
import {postLineNum} from './alpine/post-line-num'
import {postToc} from './alpine/post-toc'
import {headerDividing} from './alpine/header-dividing'
import {headerMenu} from './alpine/header-menu'
import {typewriterEffect} from './utils'

window.Alpine = Alpine

Alpine.data('upvote', upvote)
Alpine.data('themeMode', themeMode)
Alpine.data('postLineNum', postLineNum)
Alpine.data('postToc', postToc)
Alpine.data('headerMenu', headerMenu)
Alpine.data('headerDividing', headerDividing)

Alpine.start()

document.addEventListener('DOMContentLoaded', () => typewriterEffect('.typed-text'))
