implement model methods for backup
This commit is contained in:
@@ -0,0 +1,538 @@
|
|||||||
|
let SessionLoad = 1
|
||||||
|
if &cp | set nocp | endif
|
||||||
|
let s:cpo_save=&cpo
|
||||||
|
set cpo&vim
|
||||||
|
inoremap <silent> <Plug>(table-mode-tableize) |:call tablemode#TableizeInsertMode()␍a
|
||||||
|
inoremap <silent> <expr> <PageUp> coc#pum#visible() ? coc#pum#scroll(0) : "\<PageUp>"
|
||||||
|
inoremap <silent> <expr> <PageDown> coc#pum#visible() ? coc#pum#scroll(1) : "\<PageDown>"
|
||||||
|
inoremap <silent> <expr> <C-Y> coc#pum#visible() ? coc#pum#confirm() : coc#inline#visible() ? coc#inline#accept() :"\"
|
||||||
|
inoremap <silent> <expr> <C-E> coc#pum#visible() ? coc#pum#cancel() : coc#inline#visible() ? coc#inline#cancel() : "\"
|
||||||
|
inoremap <silent> <expr> <Up> coc#pum#visible() ? coc#pum#prev(0) : coc#inline#visible() ? coc#inline#prev() :"\<Up>"
|
||||||
|
inoremap <silent> <expr> <Down> coc#pum#visible() ? coc#pum#next(0) : coc#inline#visible() ? coc#inline#next() :"\<Down>"
|
||||||
|
inoremap <silent> <expr> <C-P> coc#pum#visible() ? coc#pum#prev(1) : coc#inline#visible() ? coc#inline#prev() : "\"
|
||||||
|
inoremap <silent> <expr> <C-N> coc#pum#visible() ? coc#pum#next(1) : coc#inline#visible() ? coc#inline#next() : "\"
|
||||||
|
nnoremap :NERDTreeFind
|
||||||
|
nnoremap :NERDTree
|
||||||
|
nmap <Plug>(ctrlp)
|
||||||
|
nnoremap :NERDTreeToggle
|
||||||
|
xmap \T <Plug>(table-mode-tableize-delimiter)
|
||||||
|
xmap \tt <Plug>(table-mode-tableize)
|
||||||
|
nmap \tt <Plug>(table-mode-tableize)
|
||||||
|
nnoremap <silent> \tm :call tablemode#Toggle()
|
||||||
|
nnoremap \4 :call SN("4")
|
||||||
|
nnoremap \3 :call SN("3")
|
||||||
|
nnoremap \2 :call SN("2")
|
||||||
|
nnoremap \1 :call SN("1")
|
||||||
|
nmap \rn <Plug>(coc-rename)
|
||||||
|
xmap gx <Plug>NetrwBrowseXVis
|
||||||
|
nmap gx <Plug>NetrwBrowseX
|
||||||
|
nnoremap <silent> <Plug>GitGutterPreviewHunk :call gitgutter#utility#warn('Please change your map <Plug>GitGutterPreviewHunk to <Plug>(GitGutterPreviewHunk)')
|
||||||
|
nnoremap <silent> <Plug>(GitGutterPreviewHunk) :GitGutterPreviewHunk
|
||||||
|
nnoremap <silent> <Plug>GitGutterUndoHunk :call gitgutter#utility#warn('Please change your map <Plug>GitGutterUndoHunk to <Plug>(GitGutterUndoHunk)')
|
||||||
|
nnoremap <silent> <Plug>(GitGutterUndoHunk) :GitGutterUndoHunk
|
||||||
|
nnoremap <silent> <Plug>GitGutterStageHunk :call gitgutter#utility#warn('Please change your map <Plug>GitGutterStageHunk to <Plug>(GitGutterStageHunk)')
|
||||||
|
nnoremap <silent> <Plug>(GitGutterStageHunk) :GitGutterStageHunk
|
||||||
|
xnoremap <silent> <Plug>GitGutterStageHunk :call gitgutter#utility#warn('Please change your map <Plug>GitGutterStageHunk to <Plug>(GitGutterStageHunk)')
|
||||||
|
xnoremap <silent> <Plug>(GitGutterStageHunk) :GitGutterStageHunk
|
||||||
|
nnoremap <silent> <expr> <Plug>GitGutterPrevHunk &diff ? '[c' : ":\call gitgutter#utility#warn('Please change your map \<Plug>GitGutterPrevHunk to \<Plug>(GitGutterPrevHunk)')\␍"
|
||||||
|
nnoremap <silent> <expr> <Plug>(GitGutterPrevHunk) &diff ? '[c' : ":\execute v:count1 . 'GitGutterPrevHunk'\␍"
|
||||||
|
nnoremap <silent> <expr> <Plug>GitGutterNextHunk &diff ? ']c' : ":\call gitgutter#utility#warn('Please change your map \<Plug>GitGutterNextHunk to \<Plug>(GitGutterNextHunk)')\␍"
|
||||||
|
nnoremap <silent> <expr> <Plug>(GitGutterNextHunk) &diff ? ']c' : ":\execute v:count1 . 'GitGutterNextHunk'\␍"
|
||||||
|
xnoremap <silent> <Plug>(GitGutterTextObjectOuterVisual) :call gitgutter#hunk#text_object(0)
|
||||||
|
xnoremap <silent> <Plug>(GitGutterTextObjectInnerVisual) :call gitgutter#hunk#text_object(1)
|
||||||
|
onoremap <silent> <Plug>(GitGutterTextObjectOuterPending) :call gitgutter#hunk#text_object(0)
|
||||||
|
onoremap <silent> <Plug>(GitGutterTextObjectInnerPending) :call gitgutter#hunk#text_object(1)
|
||||||
|
xnoremap <silent> <Plug>NetrwBrowseXVis :call netrw#BrowseXVis()
|
||||||
|
nnoremap <silent> <Plug>NetrwBrowseX :call netrw#BrowseX(netrw#GX(),netrw#CheckIfRemote(netrw#GX()))
|
||||||
|
nmap <C-P> <Plug>(ctrlp)
|
||||||
|
nnoremap <silent> <Plug>(ctrlp) :CtrlP
|
||||||
|
nnoremap <silent> <Plug>(table-mode-sort) :call tablemode#spreadsheet#Sort('')
|
||||||
|
nnoremap <silent> <Plug>(table-mode-echo-cell) :call tablemode#spreadsheet#EchoCell()
|
||||||
|
nnoremap <silent> <Plug>(table-mode-eval-formula) :call tablemode#spreadsheet#formula#EvaluateFormulaLine()
|
||||||
|
nnoremap <silent> <Plug>(table-mode-add-formula) :call tablemode#spreadsheet#formula#Add()
|
||||||
|
nnoremap <silent> <Plug>(table-mode-insert-column-after) :call tablemode#spreadsheet#InsertColumn(1)
|
||||||
|
nnoremap <silent> <Plug>(table-mode-insert-column-before) :call tablemode#spreadsheet#InsertColumn(0)
|
||||||
|
nnoremap <silent> <Plug>(table-mode-delete-column) :call tablemode#spreadsheet#DeleteColumn()
|
||||||
|
nnoremap <silent> <Plug>(table-mode-delete-row) :call tablemode#spreadsheet#DeleteRow()
|
||||||
|
xnoremap <silent> <Plug>(table-mode-cell-text-object-i) :call tablemode#spreadsheet#cell#TextObject(1)
|
||||||
|
xnoremap <silent> <Plug>(table-mode-cell-text-object-a) :call tablemode#spreadsheet#cell#TextObject(0)
|
||||||
|
onoremap <silent> <Plug>(table-mode-cell-text-object-i) :call tablemode#spreadsheet#cell#TextObject(1)
|
||||||
|
onoremap <silent> <Plug>(table-mode-cell-text-object-a) :call tablemode#spreadsheet#cell#TextObject(0)
|
||||||
|
nnoremap <silent> <Plug>(table-mode-motion-right) :call tablemode#spreadsheet#cell#Motion('l')
|
||||||
|
nnoremap <silent> <Plug>(table-mode-motion-left) :call tablemode#spreadsheet#cell#Motion('h')
|
||||||
|
nnoremap <silent> <Plug>(table-mode-motion-down) :call tablemode#spreadsheet#cell#Motion('j')
|
||||||
|
nnoremap <silent> <Plug>(table-mode-motion-up) :call tablemode#spreadsheet#cell#Motion('k')
|
||||||
|
nnoremap <silent> <Plug>(table-mode-realign) :call tablemode#table#Realign('.')
|
||||||
|
xnoremap <silent> <Plug>(table-mode-tableize-delimiter) :call tablemode#TableizeByDelimiter()
|
||||||
|
xnoremap <silent> <Plug>(table-mode-tableize) :Tableize
|
||||||
|
nnoremap <silent> <Plug>(table-mode-tableize) :Tableize
|
||||||
|
onoremap <silent> <Plug>(coc-classobj-a) :call CocAction('selectSymbolRange', v:false, '', ['Interface', 'Struct', 'Class'])
|
||||||
|
onoremap <silent> <Plug>(coc-classobj-i) :call CocAction('selectSymbolRange', v:true, '', ['Interface', 'Struct', 'Class'])
|
||||||
|
vnoremap <silent> <Plug>(coc-classobj-a) :call CocAction('selectSymbolRange', v:false, visualmode(), ['Interface', 'Struct', 'Class'])
|
||||||
|
vnoremap <silent> <Plug>(coc-classobj-i) :call CocAction('selectSymbolRange', v:true, visualmode(), ['Interface', 'Struct', 'Class'])
|
||||||
|
onoremap <silent> <Plug>(coc-funcobj-a) :call CocAction('selectSymbolRange', v:false, '', ['Method', 'Function'])
|
||||||
|
onoremap <silent> <Plug>(coc-funcobj-i) :call CocAction('selectSymbolRange', v:true, '', ['Method', 'Function'])
|
||||||
|
vnoremap <silent> <Plug>(coc-funcobj-a) :call CocAction('selectSymbolRange', v:false, visualmode(), ['Method', 'Function'])
|
||||||
|
vnoremap <silent> <Plug>(coc-funcobj-i) :call CocAction('selectSymbolRange', v:true, visualmode(), ['Method', 'Function'])
|
||||||
|
nnoremap <silent> <Plug>(coc-cursors-position) :call CocAction('cursorsSelect', bufnr('%'), 'position', 'n')
|
||||||
|
nnoremap <silent> <Plug>(coc-cursors-word) :call CocAction('cursorsSelect', bufnr('%'), 'word', 'n')
|
||||||
|
vnoremap <silent> <Plug>(coc-cursors-range) :call CocAction('cursorsSelect', bufnr('%'), 'range', visualmode())
|
||||||
|
nnoremap <silent> <Plug>(coc-refactor) :call CocActionAsync('refactor')
|
||||||
|
nnoremap <silent> <Plug>(coc-command-repeat) :call CocAction('repeatCommand')
|
||||||
|
nnoremap <silent> <Plug>(coc-float-jump) :call coc#float#jump()
|
||||||
|
nnoremap <silent> <Plug>(coc-float-hide) :call coc#float#close_all()
|
||||||
|
nnoremap <silent> <Plug>(coc-fix-current) :call CocActionAsync('doQuickfix')
|
||||||
|
nnoremap <silent> <Plug>(coc-openlink) :call CocActionAsync('openLink')
|
||||||
|
nnoremap <silent> <Plug>(coc-references-used) :call CocActionAsync('jumpUsed')
|
||||||
|
nnoremap <silent> <Plug>(coc-references) :call CocActionAsync('jumpReferences')
|
||||||
|
nnoremap <silent> <Plug>(coc-type-definition) :call CocActionAsync('jumpTypeDefinition')
|
||||||
|
nnoremap <silent> <Plug>(coc-implementation) :call CocActionAsync('jumpImplementation')
|
||||||
|
nnoremap <silent> <Plug>(coc-declaration) :call CocActionAsync('jumpDeclaration')
|
||||||
|
nnoremap <silent> <Plug>(coc-definition) :call CocActionAsync('jumpDefinition')
|
||||||
|
nnoremap <silent> <Plug>(coc-diagnostic-prev-error) :call CocActionAsync('diagnosticPrevious', 'error')
|
||||||
|
nnoremap <silent> <Plug>(coc-diagnostic-next-error) :call CocActionAsync('diagnosticNext', 'error')
|
||||||
|
nnoremap <silent> <Plug>(coc-diagnostic-prev) :call CocActionAsync('diagnosticPrevious')
|
||||||
|
nnoremap <silent> <Plug>(coc-diagnostic-next) :call CocActionAsync('diagnosticNext')
|
||||||
|
nnoremap <silent> <Plug>(coc-diagnostic-info) :call CocActionAsync('diagnosticInfo')
|
||||||
|
nnoremap <silent> <Plug>(coc-format) :call CocActionAsync('format')
|
||||||
|
nnoremap <silent> <Plug>(coc-rename) :call CocActionAsync('rename')
|
||||||
|
nnoremap <Plug>(coc-codeaction-source) :call CocActionAsync('codeAction', '', ['source'], v:true)
|
||||||
|
nnoremap <Plug>(coc-codeaction-refactor) :call CocActionAsync('codeAction', 'cursor', ['refactor'], v:true)
|
||||||
|
nnoremap <Plug>(coc-codeaction-cursor) :call CocActionAsync('codeAction', 'cursor')
|
||||||
|
nnoremap <Plug>(coc-codeaction-line) :call CocActionAsync('codeAction', 'currline')
|
||||||
|
nnoremap <Plug>(coc-codeaction) :call CocActionAsync('codeAction', '')
|
||||||
|
vnoremap <Plug>(coc-codeaction-refactor-selected) :call CocActionAsync('codeAction', visualmode(), ['refactor'], v:true)
|
||||||
|
vnoremap <silent> <Plug>(coc-codeaction-selected) :call CocActionAsync('codeAction', visualmode())
|
||||||
|
vnoremap <silent> <Plug>(coc-format-selected) :call CocActionAsync('formatSelected', visualmode())
|
||||||
|
nnoremap <Plug>(coc-codelens-action) :call CocActionAsync('codeLensAction')
|
||||||
|
nnoremap <Plug>(coc-range-select) :call CocActionAsync('rangeSelect', '', v:true)
|
||||||
|
vnoremap <silent> <Plug>(coc-range-select-backward) :call CocActionAsync('rangeSelect', visualmode(), v:false)
|
||||||
|
vnoremap <silent> <Plug>(coc-range-select) :call CocActionAsync('rangeSelect', visualmode(), v:true)
|
||||||
|
nnoremap <C-F> :NERDTreeFind
|
||||||
|
nnoremap <C-T> :NERDTreeToggle
|
||||||
|
nnoremap <C-N> :NERDTree
|
||||||
|
inoremap <silent> <expr> coc#pum#visible() ? coc#pum#cancel() : coc#inline#visible() ? coc#inline#cancel() : "\"
|
||||||
|
inoremap <nowait> <silent> <expr> ␍ coc#pum#visible() ? coc#pum#confirm() : "\␍"
|
||||||
|
inoremap <silent> <expr> coc#pum#visible() ? coc#pum#next(1) : coc#inline#visible() ? coc#inline#next() : "\"
|
||||||
|
inoremap <silent> <expr> coc#pum#visible() ? coc#pum#prev(1) : coc#inline#visible() ? coc#inline#prev() : "\"
|
||||||
|
inoremap <silent> <expr> coc#pum#visible() ? coc#pum#confirm() : coc#inline#visible() ? coc#inline#accept() :"\"
|
||||||
|
let &cpo=s:cpo_save
|
||||||
|
unlet s:cpo_save
|
||||||
|
set autoread
|
||||||
|
set background=dark
|
||||||
|
set backspace=indent,eol,start
|
||||||
|
set encoding=utf-8
|
||||||
|
set fileencodings=ucs-bom,utf-8,default,latin1
|
||||||
|
set nomodeline
|
||||||
|
set mouse=a
|
||||||
|
set printoptions=paper:a4
|
||||||
|
set ruler
|
||||||
|
set runtimepath=~/.vim,~/.vim/pack/airblade/start/vim-gitgutter,~/.vim/plugged/coc.nvim,~/.vim/plugged/emmet-vim,~/.vim/plugged/nerdtree,~/.vim/plugged/typescript-vim,~/.vim/plugged/vim-jsx-typescript,~/.vim/plugged/vim-table-mode,~/.vim/plugged/ctrlp.vim,/var/lib/vim/addons,/etc/vim,/usr/share/vim/vimfiles,/usr/share/vim/vim90,/usr/share/vim/vimfiles/after,/etc/vim/after,/var/lib/vim/addons/after,~/.vim/plugged/vim-jsx-typescript/after,~/.vim/after
|
||||||
|
set shiftwidth=4
|
||||||
|
set smarttab
|
||||||
|
set suffixes=.bak,~,.swp,.o,.info,.aux,.log,.dvi,.bbl,.blg,.brf,.cb,.ind,.idx,.ilg,.inx,.out,.toc
|
||||||
|
set updatetime=500
|
||||||
|
let s:so_save = &g:so | let s:siso_save = &g:siso | setg so=0 siso=0 | setl so=-1 siso=-1
|
||||||
|
let v:this_session=expand("<sfile>:p")
|
||||||
|
silent only
|
||||||
|
silent tabonly
|
||||||
|
cd ~/storage/VDMDI/Comms
|
||||||
|
if expand('%') == '' && !&modified && line('$') <= 1 && getline(1) == ''
|
||||||
|
let s:wipebuf = bufnr('%')
|
||||||
|
endif
|
||||||
|
if &shortmess =~ 'A'
|
||||||
|
set shortmess=aoOA
|
||||||
|
else
|
||||||
|
set shortmess=aoO
|
||||||
|
endif
|
||||||
|
badd +0 src/Model/Global/fileTransferModel.ts
|
||||||
|
argglobal
|
||||||
|
%argdel
|
||||||
|
edit src/Model/Global/fileTransferModel.ts
|
||||||
|
let s:save_splitbelow = &splitbelow
|
||||||
|
let s:save_splitright = &splitright
|
||||||
|
set splitbelow splitright
|
||||||
|
wincmd _ | wincmd |
|
||||||
|
vsplit
|
||||||
|
1wincmd h
|
||||||
|
wincmd w
|
||||||
|
let &splitbelow = s:save_splitbelow
|
||||||
|
let &splitright = s:save_splitright
|
||||||
|
wincmd t
|
||||||
|
let s:save_winminheight = &winminheight
|
||||||
|
let s:save_winminwidth = &winminwidth
|
||||||
|
set winminheight=0
|
||||||
|
set winheight=1
|
||||||
|
set winminwidth=0
|
||||||
|
set winwidth=1
|
||||||
|
exe 'vert 1resize ' . ((&columns * 31 + 127) / 255)
|
||||||
|
exe 'vert 2resize ' . ((&columns * 223 + 127) / 255)
|
||||||
|
argglobal
|
||||||
|
enew
|
||||||
|
file NERD_tree_tab_1
|
||||||
|
balt src/Model/Global/fileTransferModel.ts
|
||||||
|
let s:cpo_save=&cpo
|
||||||
|
set cpo&vim
|
||||||
|
nnoremap <buffer> <silent> <NL> :call nerdtree#ui_glue#invokeKeyMap("<C-j>")
|
||||||
|
nnoremap <buffer> <silent> :call nerdtree#ui_glue#invokeKeyMap("<C-k>")
|
||||||
|
nnoremap <buffer> <silent> ␍ :call nerdtree#ui_glue#invokeKeyMap("<CR>")
|
||||||
|
nnoremap <buffer> <silent> ? :call nerdtree#ui_glue#invokeKeyMap("?")
|
||||||
|
nnoremap <buffer> <silent> A :call nerdtree#ui_glue#invokeKeyMap("A")
|
||||||
|
nnoremap <buffer> <silent> B :call nerdtree#ui_glue#invokeKeyMap("B")
|
||||||
|
nnoremap <buffer> <silent> C :call nerdtree#ui_glue#invokeKeyMap("C")
|
||||||
|
nnoremap <buffer> <silent> CD :call nerdtree#ui_glue#invokeKeyMap("CD")
|
||||||
|
nnoremap <buffer> <silent> D :call nerdtree#ui_glue#invokeKeyMap("D")
|
||||||
|
nnoremap <buffer> <silent> FL :call nerdtree#ui_glue#invokeKeyMap("FL")
|
||||||
|
nnoremap <buffer> <silent> F :call nerdtree#ui_glue#invokeKeyMap("F")
|
||||||
|
nnoremap <buffer> <silent> I :call nerdtree#ui_glue#invokeKeyMap("I")
|
||||||
|
nnoremap <buffer> <silent> J :call nerdtree#ui_glue#invokeKeyMap("J")
|
||||||
|
nnoremap <buffer> <silent> K :call nerdtree#ui_glue#invokeKeyMap("K")
|
||||||
|
nnoremap <buffer> <silent> O :call nerdtree#ui_glue#invokeKeyMap("O")
|
||||||
|
nnoremap <buffer> <silent> P :call nerdtree#ui_glue#invokeKeyMap("P")
|
||||||
|
nnoremap <buffer> <silent> R :call nerdtree#ui_glue#invokeKeyMap("R")
|
||||||
|
nnoremap <buffer> <silent> T :call nerdtree#ui_glue#invokeKeyMap("T")
|
||||||
|
nnoremap <buffer> <silent> U :call nerdtree#ui_glue#invokeKeyMap("U")
|
||||||
|
nnoremap <buffer> <silent> X :call nerdtree#ui_glue#invokeKeyMap("X")
|
||||||
|
nmap <buffer> [c <Plug>(GitGutterPrevHunk)
|
||||||
|
nmap <buffer> \hp <Plug>(GitGutterPreviewHunk)
|
||||||
|
nmap <buffer> \hu <Plug>(GitGutterUndoHunk)
|
||||||
|
nmap <buffer> \hs <Plug>(GitGutterStageHunk)
|
||||||
|
xmap <buffer> \hs <Plug>(GitGutterStageHunk)
|
||||||
|
nmap <buffer> ]c <Plug>(GitGutterNextHunk)
|
||||||
|
xmap <buffer> ac <Plug>(GitGutterTextObjectOuterVisual)
|
||||||
|
omap <buffer> ac <Plug>(GitGutterTextObjectOuterPending)
|
||||||
|
nnoremap <buffer> <silent> cd :call nerdtree#ui_glue#invokeKeyMap("cd")
|
||||||
|
nnoremap <buffer> <silent> e :call nerdtree#ui_glue#invokeKeyMap("e")
|
||||||
|
nnoremap <buffer> <silent> f :call nerdtree#ui_glue#invokeKeyMap("f")
|
||||||
|
nnoremap <buffer> <silent> go :call nerdtree#ui_glue#invokeKeyMap("go")
|
||||||
|
nnoremap <buffer> <silent> gb :call nerdtree#ui_glue#invokeKeyMap("gb")
|
||||||
|
nnoremap <buffer> <silent> gi :call nerdtree#ui_glue#invokeKeyMap("gi")
|
||||||
|
nnoremap <buffer> <silent> gs :call nerdtree#ui_glue#invokeKeyMap("gs")
|
||||||
|
xmap <buffer> ic <Plug>(GitGutterTextObjectInnerVisual)
|
||||||
|
omap <buffer> ic <Plug>(GitGutterTextObjectInnerPending)
|
||||||
|
nnoremap <buffer> <silent> i :call nerdtree#ui_glue#invokeKeyMap("i")
|
||||||
|
nnoremap <buffer> <silent> m :call nerdtree#ui_glue#invokeKeyMap("m")
|
||||||
|
nnoremap <buffer> <silent> o :call nerdtree#ui_glue#invokeKeyMap("o")
|
||||||
|
nnoremap <buffer> <silent> p :call nerdtree#ui_glue#invokeKeyMap("p")
|
||||||
|
nnoremap <buffer> <silent> q :call nerdtree#ui_glue#invokeKeyMap("q")
|
||||||
|
nnoremap <buffer> <silent> r :call nerdtree#ui_glue#invokeKeyMap("r")
|
||||||
|
nnoremap <buffer> <silent> s :call nerdtree#ui_glue#invokeKeyMap("s")
|
||||||
|
nnoremap <buffer> <silent> t :call nerdtree#ui_glue#invokeKeyMap("t")
|
||||||
|
nnoremap <buffer> <silent> u :call nerdtree#ui_glue#invokeKeyMap("u")
|
||||||
|
nnoremap <buffer> <silent> x :call nerdtree#ui_glue#invokeKeyMap("x")
|
||||||
|
nnoremap <buffer> <silent> <MiddleMouse> :call nerdtree#ui_glue#invokeKeyMap("<MiddleMouse>")
|
||||||
|
nnoremap <buffer> <silent> <2-LeftMouse> :call nerdtree#ui_glue#invokeKeyMap("<2-LeftMouse>")
|
||||||
|
nnoremap <buffer> <silent> <C-K> :call nerdtree#ui_glue#invokeKeyMap("<C-k>")
|
||||||
|
nnoremap <buffer> <silent> <C-J> :call nerdtree#ui_glue#invokeKeyMap("<C-j>")
|
||||||
|
nnoremap <buffer> <silent> <LeftRelease> <LeftRelease>:call nerdtree#ui_glue#invokeKeyMap("<LeftRelease>")
|
||||||
|
let &cpo=s:cpo_save
|
||||||
|
unlet s:cpo_save
|
||||||
|
setlocal keymap=
|
||||||
|
setlocal noarabic
|
||||||
|
setlocal noautoindent
|
||||||
|
setlocal backupcopy=
|
||||||
|
setlocal balloonexpr=
|
||||||
|
setlocal nobinary
|
||||||
|
setlocal nobreakindent
|
||||||
|
setlocal breakindentopt=
|
||||||
|
setlocal bufhidden=hide
|
||||||
|
setlocal nobuflisted
|
||||||
|
setlocal buftype=nofile
|
||||||
|
setlocal nocindent
|
||||||
|
setlocal cinkeys=0{,0},0),0],:,0#,!^F,o,O,e
|
||||||
|
setlocal cinoptions=
|
||||||
|
setlocal cinscopedecls=public,protected,private
|
||||||
|
setlocal cinwords=if,else,while,do,for,switch
|
||||||
|
setlocal colorcolumn=
|
||||||
|
setlocal comments=s1:/*,mb:*,ex:*/,://,b:#,:%,:XCOMM,n:>,fb:-
|
||||||
|
setlocal commentstring=/*%s*/
|
||||||
|
setlocal complete=.,w,b,u,t,i
|
||||||
|
setlocal concealcursor=nvic
|
||||||
|
setlocal conceallevel=2
|
||||||
|
setlocal completefunc=
|
||||||
|
setlocal nocopyindent
|
||||||
|
setlocal cryptmethod=
|
||||||
|
setlocal nocursorbind
|
||||||
|
setlocal nocursorcolumn
|
||||||
|
setlocal cursorline
|
||||||
|
setlocal cursorlineopt=both
|
||||||
|
setlocal define=
|
||||||
|
setlocal dictionary=
|
||||||
|
setlocal nodiff
|
||||||
|
setlocal equalprg=
|
||||||
|
setlocal errorformat=
|
||||||
|
setlocal noexpandtab
|
||||||
|
if &filetype != 'nerdtree'
|
||||||
|
setlocal filetype=nerdtree
|
||||||
|
endif
|
||||||
|
setlocal fillchars=
|
||||||
|
setlocal fixendofline
|
||||||
|
setlocal foldcolumn=0
|
||||||
|
setlocal nofoldenable
|
||||||
|
setlocal foldexpr=0
|
||||||
|
setlocal foldignore=#
|
||||||
|
setlocal foldlevel=0
|
||||||
|
setlocal foldmarker={{{,}}}
|
||||||
|
setlocal foldmethod=manual
|
||||||
|
setlocal foldminlines=1
|
||||||
|
setlocal foldnestmax=20
|
||||||
|
setlocal foldtext=foldtext()
|
||||||
|
setlocal formatexpr=
|
||||||
|
setlocal formatoptions=tcq
|
||||||
|
setlocal formatlistpat=^\\s*\\d\\+[\\]:.)}\\t\ ]\\s*
|
||||||
|
setlocal formatprg=
|
||||||
|
setlocal grepprg=
|
||||||
|
setlocal iminsert=0
|
||||||
|
setlocal imsearch=-1
|
||||||
|
setlocal include=
|
||||||
|
setlocal includeexpr=
|
||||||
|
setlocal indentexpr=
|
||||||
|
setlocal indentkeys=0{,0},0),0],:,0#,!^F,o,O,e
|
||||||
|
setlocal noinfercase
|
||||||
|
setlocal iskeyword=@,48-57,_,192-255
|
||||||
|
setlocal keywordprg=
|
||||||
|
setlocal nolinebreak
|
||||||
|
setlocal nolisp
|
||||||
|
setlocal lispoptions=
|
||||||
|
setlocal lispwords=
|
||||||
|
setlocal nolist
|
||||||
|
setlocal listchars=
|
||||||
|
setlocal makeencoding=
|
||||||
|
setlocal makeprg=
|
||||||
|
setlocal matchpairs=(:),{:},[:]
|
||||||
|
setlocal nomodeline
|
||||||
|
setlocal nomodifiable
|
||||||
|
setlocal nrformats=bin,octal,hex
|
||||||
|
set number
|
||||||
|
setlocal nonumber
|
||||||
|
setlocal numberwidth=4
|
||||||
|
setlocal omnifunc=
|
||||||
|
setlocal path=
|
||||||
|
setlocal nopreserveindent
|
||||||
|
setlocal nopreviewwindow
|
||||||
|
setlocal quoteescape=\\
|
||||||
|
setlocal readonly
|
||||||
|
setlocal norelativenumber
|
||||||
|
setlocal norightleft
|
||||||
|
setlocal rightleftcmd=search
|
||||||
|
setlocal noscrollbind
|
||||||
|
setlocal scrolloff=-1
|
||||||
|
setlocal shiftwidth=4
|
||||||
|
setlocal noshortname
|
||||||
|
setlocal showbreak=
|
||||||
|
setlocal sidescrolloff=-1
|
||||||
|
set signcolumn=yes
|
||||||
|
setlocal signcolumn=yes
|
||||||
|
setlocal nosmartindent
|
||||||
|
setlocal nosmoothscroll
|
||||||
|
setlocal softtabstop=0
|
||||||
|
setlocal nospell
|
||||||
|
setlocal spellcapcheck=[.?!]\\_[\\])'\"\ \ ]\\+
|
||||||
|
setlocal spellfile=
|
||||||
|
setlocal spelllang=en
|
||||||
|
setlocal spelloptions=
|
||||||
|
setlocal statusline=%{exists('b:NERDTree')?b:NERDTree.root.path.str():''}
|
||||||
|
setlocal suffixesadd=
|
||||||
|
setlocal noswapfile
|
||||||
|
setlocal synmaxcol=3000
|
||||||
|
if &syntax != 'nerdtree'
|
||||||
|
setlocal syntax=nerdtree
|
||||||
|
endif
|
||||||
|
setlocal tabstop=8
|
||||||
|
setlocal tagcase=
|
||||||
|
setlocal tagfunc=
|
||||||
|
setlocal tags=
|
||||||
|
setlocal termwinkey=
|
||||||
|
setlocal termwinscroll=10000
|
||||||
|
setlocal termwinsize=
|
||||||
|
setlocal textwidth=0
|
||||||
|
setlocal thesaurus=
|
||||||
|
setlocal thesaurusfunc=
|
||||||
|
setlocal noundofile
|
||||||
|
setlocal undolevels=-123456
|
||||||
|
setlocal varsofttabstop=
|
||||||
|
setlocal vartabstop=
|
||||||
|
setlocal virtualedit=
|
||||||
|
setlocal wincolor=
|
||||||
|
setlocal nowinfixheight
|
||||||
|
setlocal winfixwidth
|
||||||
|
setlocal nowrap
|
||||||
|
setlocal wrapmargin=0
|
||||||
|
wincmd w
|
||||||
|
argglobal
|
||||||
|
balt src/Model/Global/fileTransferModel.ts
|
||||||
|
let s:cpo_save=&cpo
|
||||||
|
set cpo&vim
|
||||||
|
nmap <buffer> [c <Plug>(GitGutterPrevHunk)
|
||||||
|
nmap <buffer> \hp <Plug>(GitGutterPreviewHunk)
|
||||||
|
nmap <buffer> \hu <Plug>(GitGutterUndoHunk)
|
||||||
|
nmap <buffer> \hs <Plug>(GitGutterStageHunk)
|
||||||
|
xmap <buffer> \hs <Plug>(GitGutterStageHunk)
|
||||||
|
nmap <buffer> ]c <Plug>(GitGutterNextHunk)
|
||||||
|
xmap <buffer> ac <Plug>(GitGutterTextObjectOuterVisual)
|
||||||
|
omap <buffer> ac <Plug>(GitGutterTextObjectOuterPending)
|
||||||
|
xmap <buffer> ic <Plug>(GitGutterTextObjectInnerVisual)
|
||||||
|
omap <buffer> ic <Plug>(GitGutterTextObjectInnerPending)
|
||||||
|
let &cpo=s:cpo_save
|
||||||
|
unlet s:cpo_save
|
||||||
|
setlocal keymap=
|
||||||
|
setlocal noarabic
|
||||||
|
setlocal autoindent
|
||||||
|
setlocal backupcopy=
|
||||||
|
setlocal balloonexpr=
|
||||||
|
setlocal nobinary
|
||||||
|
setlocal nobreakindent
|
||||||
|
setlocal breakindentopt=
|
||||||
|
setlocal bufhidden=
|
||||||
|
setlocal buflisted
|
||||||
|
setlocal buftype=
|
||||||
|
setlocal nocindent
|
||||||
|
setlocal cinkeys=0{,0},0),0],:,0#,!^F,o,O,e
|
||||||
|
setlocal cinoptions=
|
||||||
|
setlocal cinscopedecls=public,protected,private
|
||||||
|
setlocal cinwords=if,else,while,do,for,switch
|
||||||
|
setlocal colorcolumn=
|
||||||
|
setlocal comments=s1:/*,mb:*,ex:*/,://,b:#,:%,:XCOMM,n:>,fb:-
|
||||||
|
setlocal commentstring=//\ %s
|
||||||
|
setlocal complete=.,w,b,u,t,i
|
||||||
|
setlocal concealcursor=
|
||||||
|
setlocal conceallevel=0
|
||||||
|
setlocal completefunc=
|
||||||
|
setlocal nocopyindent
|
||||||
|
setlocal cryptmethod=
|
||||||
|
setlocal nocursorbind
|
||||||
|
setlocal nocursorcolumn
|
||||||
|
setlocal nocursorline
|
||||||
|
setlocal cursorlineopt=both
|
||||||
|
setlocal define=
|
||||||
|
setlocal dictionary=
|
||||||
|
setlocal nodiff
|
||||||
|
setlocal equalprg=
|
||||||
|
setlocal errorformat=%+A\ %#%f\ %#(%l\\,%c):\ %m,%C%m
|
||||||
|
setlocal noexpandtab
|
||||||
|
if &filetype != 'typescript'
|
||||||
|
setlocal filetype=typescript
|
||||||
|
endif
|
||||||
|
setlocal fillchars=
|
||||||
|
setlocal fixendofline
|
||||||
|
setlocal foldcolumn=0
|
||||||
|
setlocal foldenable
|
||||||
|
setlocal foldexpr=0
|
||||||
|
setlocal foldignore=#
|
||||||
|
setlocal foldlevel=0
|
||||||
|
setlocal foldmarker={{{,}}}
|
||||||
|
setlocal foldmethod=manual
|
||||||
|
setlocal foldminlines=1
|
||||||
|
setlocal foldnestmax=20
|
||||||
|
setlocal foldtext=foldtext()
|
||||||
|
setlocal formatexpr=
|
||||||
|
setlocal formatoptions=croql
|
||||||
|
setlocal formatlistpat=^\\s*\\d\\+[\\]:.)}\\t\ ]\\s*
|
||||||
|
setlocal formatprg=
|
||||||
|
setlocal grepprg=
|
||||||
|
setlocal iminsert=0
|
||||||
|
setlocal imsearch=-1
|
||||||
|
setlocal include=
|
||||||
|
setlocal includeexpr=
|
||||||
|
setlocal indentexpr=GetTypescriptIndent()
|
||||||
|
setlocal indentkeys=0{,0},0),0],:,0#,!^F,o,O,e,0],0)
|
||||||
|
setlocal noinfercase
|
||||||
|
setlocal iskeyword=@,48-57,_,192-255,$
|
||||||
|
setlocal keywordprg=
|
||||||
|
setlocal nolinebreak
|
||||||
|
setlocal nolisp
|
||||||
|
setlocal lispoptions=
|
||||||
|
setlocal lispwords=
|
||||||
|
setlocal nolist
|
||||||
|
setlocal listchars=
|
||||||
|
setlocal makeencoding=
|
||||||
|
setlocal makeprg=tsc\ \ $*\ %
|
||||||
|
setlocal matchpairs=(:),{:},[:]
|
||||||
|
setlocal nomodeline
|
||||||
|
setlocal modifiable
|
||||||
|
setlocal nrformats=bin,octal,hex
|
||||||
|
set number
|
||||||
|
setlocal number
|
||||||
|
setlocal numberwidth=4
|
||||||
|
setlocal omnifunc=
|
||||||
|
setlocal path=
|
||||||
|
setlocal nopreserveindent
|
||||||
|
setlocal nopreviewwindow
|
||||||
|
setlocal quoteescape=\\
|
||||||
|
setlocal noreadonly
|
||||||
|
setlocal norelativenumber
|
||||||
|
setlocal norightleft
|
||||||
|
setlocal rightleftcmd=search
|
||||||
|
setlocal noscrollbind
|
||||||
|
setlocal scrolloff=-1
|
||||||
|
setlocal shiftwidth=4
|
||||||
|
setlocal noshortname
|
||||||
|
setlocal showbreak=
|
||||||
|
setlocal sidescrolloff=-1
|
||||||
|
set signcolumn=yes
|
||||||
|
setlocal signcolumn=yes
|
||||||
|
setlocal nosmartindent
|
||||||
|
setlocal nosmoothscroll
|
||||||
|
setlocal softtabstop=0
|
||||||
|
setlocal nospell
|
||||||
|
setlocal spellcapcheck=[.?!]\\_[\\])'\"\ \ ]\\+
|
||||||
|
setlocal spellfile=
|
||||||
|
setlocal spelllang=en
|
||||||
|
setlocal spelloptions=
|
||||||
|
setlocal statusline=
|
||||||
|
setlocal suffixesadd=.ts,.tsx
|
||||||
|
setlocal swapfile
|
||||||
|
setlocal synmaxcol=3000
|
||||||
|
if &syntax != 'typescript'
|
||||||
|
setlocal syntax=typescript
|
||||||
|
endif
|
||||||
|
setlocal tabstop=8
|
||||||
|
setlocal tagcase=
|
||||||
|
setlocal tagfunc=
|
||||||
|
setlocal tags=
|
||||||
|
setlocal termwinkey=
|
||||||
|
setlocal termwinscroll=10000
|
||||||
|
setlocal termwinsize=
|
||||||
|
setlocal textwidth=0
|
||||||
|
setlocal thesaurus=
|
||||||
|
setlocal thesaurusfunc=
|
||||||
|
setlocal noundofile
|
||||||
|
setlocal undolevels=-123456
|
||||||
|
setlocal varsofttabstop=
|
||||||
|
setlocal vartabstop=
|
||||||
|
setlocal virtualedit=
|
||||||
|
setlocal wincolor=
|
||||||
|
setlocal nowinfixheight
|
||||||
|
setlocal nowinfixwidth
|
||||||
|
setlocal wrap
|
||||||
|
setlocal wrapmargin=0
|
||||||
|
silent! normal! zE
|
||||||
|
let &fdl = &fdl
|
||||||
|
let s:l = 101 - ((4 * winheight(0) + 24) / 48)
|
||||||
|
if s:l < 1 | let s:l = 1 | endif
|
||||||
|
keepjumps exe s:l
|
||||||
|
normal! zt
|
||||||
|
keepjumps 101
|
||||||
|
normal! 05|
|
||||||
|
wincmd w
|
||||||
|
2wincmd w
|
||||||
|
exe 'vert 1resize ' . ((&columns * 31 + 127) / 255)
|
||||||
|
exe 'vert 2resize ' . ((&columns * 223 + 127) / 255)
|
||||||
|
tabnext 1
|
||||||
|
if exists('s:wipebuf') && len(win_findbuf(s:wipebuf)) == 0
|
||||||
|
silent exe 'bwipe ' . s:wipebuf
|
||||||
|
endif
|
||||||
|
unlet! s:wipebuf
|
||||||
|
set winheight=1 winwidth=20
|
||||||
|
set shortmess=filnxtToOS
|
||||||
|
let &winminheight = s:save_winminheight
|
||||||
|
let &winminwidth = s:save_winminwidth
|
||||||
|
let s:sx = expand("<sfile>:p:r")."x.vim"
|
||||||
|
if filereadable(s:sx)
|
||||||
|
exe "source " . fnameescape(s:sx)
|
||||||
|
endif
|
||||||
|
let &g:so = s:so_save | let &g:siso = s:siso_save
|
||||||
|
nohlsearch
|
||||||
|
doautoall SessionLoadPost
|
||||||
|
unlet SessionLoad
|
||||||
|
" vim: set ft=vim :
|
||||||
@@ -3,12 +3,14 @@
|
|||||||
UDN-Comms is a messenger built for [UDN](https://github.com/marlon-erler/universal-decentralized-network).
|
UDN-Comms is a messenger built for [UDN](https://github.com/marlon-erler/universal-decentralized-network).
|
||||||
|
|
||||||
# Features
|
# Features
|
||||||
|
|
||||||
- Offline support
|
- Offline support
|
||||||
- Encryption
|
- Encryption
|
||||||
- Secondary channels
|
- Secondary channels
|
||||||
|
|
||||||
# Getting Started
|
# Getting Started
|
||||||
|
|
||||||
1. Use or install the web app [here](https://udn-comms.onrender.com/)
|
1. Use or install the web app [here](https://udn-comms.onrender.com/)
|
||||||
3. Enter your name
|
2. Enter your name
|
||||||
2. Connect to your server
|
3. Connect to your server
|
||||||
3. Create a chat and start messaging
|
4. Create a chat and start messaging
|
||||||
|
|||||||
Vendored
+128
-49
@@ -1,5 +1,5 @@
|
|||||||
/* src/colors.css */
|
/* src/colors.css */
|
||||||
[color]:not([color=standard]) {
|
[color]:not([color="standard"]) {
|
||||||
--primary: hsl(var(--hue), 100%, var(--accent-luma));
|
--primary: hsl(var(--hue), 100%, var(--accent-luma));
|
||||||
--primary-hover: hsl(var(--hue), 95%, var(--accent-luma));
|
--primary-hover: hsl(var(--hue), 95%, var(--accent-luma));
|
||||||
--primary-active: hsl(var(--hue), 80%, var(--accent-luma));
|
--primary-active: hsl(var(--hue), 80%, var(--accent-luma));
|
||||||
@@ -9,74 +9,72 @@
|
|||||||
--surface-hover: hsla(var(--hue), 100%, 5%, 10%);
|
--surface-hover: hsla(var(--hue), 100%, 5%, 10%);
|
||||||
--surface-active: hsla(var(--hue), 100%, 5%, 15%);
|
--surface-active: hsla(var(--hue), 100%, 5%, 15%);
|
||||||
}
|
}
|
||||||
body[theme=dark] [color]:not([color=standard]) {
|
body[theme="dark"] [color]:not([color="standard"]) {
|
||||||
--accent-luma: var(--accent-luma-dark);
|
--accent-luma: var(--accent-luma-dark);
|
||||||
--accent-text-luma: var(--accent-text-luma-dark);
|
--accent-text-luma: var(--accent-text-luma-dark);
|
||||||
--surface: hsla(var(--hue), 100%, 95%, 5%);
|
--surface: hsla(var(--hue), 100%, 95%, 5%);
|
||||||
--surface-hover: hsla(var(--hue), 100%, 95%, 10%);
|
--surface-hover: hsla(var(--hue), 100%, 95%, 10%);
|
||||||
--surface-active: hsla(var(--hue), 100%, 95%, 15%);
|
--surface-active: hsla(var(--hue), 100%, 95%, 15%);
|
||||||
}
|
}
|
||||||
[color]:not([color=standard]).tile {
|
[color]:not([color="standard"]).tile {
|
||||||
--gradient-luma-1: 70%;
|
--gradient-luma-1: 70%;
|
||||||
--gradient-luma-2: 90%;
|
--gradient-luma-2: 90%;
|
||||||
--hover-luma: 75%;
|
--hover-luma: 75%;
|
||||||
--active-luma: 80%;
|
--active-luma: 80%;
|
||||||
--text-luma: 20%;
|
--text-luma: 20%;
|
||||||
--surface:
|
--surface: linear-gradient(
|
||||||
linear-gradient(
|
|
||||||
|
|
||||||
120deg,
|
120deg,
|
||||||
hsl(var(--hue), 100%, var(--gradient-luma-1)),
|
hsl(var(--hue), 100%, var(--gradient-luma-1)),
|
||||||
hsla(var(--hue), 100%, var(--gradient-luma-2), 40%) );
|
hsla(var(--hue), 100%, var(--gradient-luma-2), 40%)
|
||||||
|
);
|
||||||
--surface-hover: hsl(var(--hue), 100%, var(--hover-luma));
|
--surface-hover: hsl(var(--hue), 100%, var(--hover-luma));
|
||||||
--surface-active: hsl(var(--hue), 100%, var(--active-luma));
|
--surface-active: hsl(var(--hue), 100%, var(--active-luma));
|
||||||
--text-normal: hsl(var(--hue), 100%, var(--text-luma));
|
--text-normal: hsl(var(--hue), 100%, var(--text-luma));
|
||||||
}
|
}
|
||||||
body[theme=dark] [color]:not([color=standard]).tile {
|
body[theme="dark"] [color]:not([color="standard"]).tile {
|
||||||
--gradient-luma-1: 20%;
|
--gradient-luma-1: 20%;
|
||||||
--gradient-luma-2: 15%;
|
--gradient-luma-2: 15%;
|
||||||
--hover-luma: 25%;
|
--hover-luma: 25%;
|
||||||
--active-luma: 30%;
|
--active-luma: 30%;
|
||||||
--text-luma: 90%;
|
--text-luma: 90%;
|
||||||
--surface:
|
--surface: linear-gradient(
|
||||||
linear-gradient(
|
|
||||||
|
|
||||||
120deg,
|
120deg,
|
||||||
hsl(var(--hue), 100%, var(--gradient-luma-1)),
|
hsl(var(--hue), 100%, var(--gradient-luma-1)),
|
||||||
hsla(var(--hue), 100%, var(--gradient-luma-2), 40%) );
|
hsla(var(--hue), 100%, var(--gradient-luma-2), 40%)
|
||||||
|
);
|
||||||
--surface-hover: hsl(var(--hue), 100%, var(--hover-luma));
|
--surface-hover: hsl(var(--hue), 100%, var(--hover-luma));
|
||||||
--surface-active: hsl(var(--hue), 100%, var(--active-luma));
|
--surface-active: hsl(var(--hue), 100%, var(--active-luma));
|
||||||
--text-normal: hsl(var(--hue), 100%, var(--text-luma));
|
--text-normal: hsl(var(--hue), 100%, var(--text-luma));
|
||||||
}
|
}
|
||||||
[color]:not([color=standard]).fill-color {
|
[color]:not([color="standard"]).fill-color {
|
||||||
color: white;
|
color: white;
|
||||||
background-color: var(--primary);
|
background-color: var(--primary);
|
||||||
}
|
}
|
||||||
[color]:not([color=standard])[selected].fill-color {
|
[color]:not([color="standard"])[selected].fill-color {
|
||||||
color: var(--primary);
|
color: var(--primary);
|
||||||
}
|
}
|
||||||
@media (min-width: 1024px) {
|
@media (min-width: 1024px) {
|
||||||
[color]:not([color=standard]).background {
|
[color]:not([color="standard"]).background {
|
||||||
--luma: var(--background-luma);
|
--luma: var(--background-luma);
|
||||||
--sat: 100%;
|
--sat: 100%;
|
||||||
background: hsl(var(--hue), var(--sat), var(--luma), 40%);
|
background: hsl(var(--hue), var(--sat), var(--luma), 40%);
|
||||||
}
|
}
|
||||||
body[theme=dark] [color]:not([color=standard]).background {
|
body[theme="dark"] [color]:not([color="standard"]).background {
|
||||||
--luma: var(--background-luma-dark);
|
--luma: var(--background-luma-dark);
|
||||||
--sat: 100%;
|
--sat: 100%;
|
||||||
}
|
}
|
||||||
[color=standard].background {
|
[color="standard"].background {
|
||||||
background: var(--surface);
|
background: var(--surface);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
[color]:not([color=standard]).subtle-background {
|
[color]:not([color="standard"]).subtle-background {
|
||||||
--luma: var(--subtle-luma);
|
--luma: var(--subtle-luma);
|
||||||
background: hsl(var(--hue), 100%, var(--luma), 50%);
|
background: hsl(var(--hue), 100%, var(--luma), 50%);
|
||||||
}
|
}
|
||||||
body[theme=dark] [color]:not([color=standard]).subtle-background {
|
body[theme="dark"] [color]:not([color="standard"]).subtle-background {
|
||||||
--luma: var(--subtle-luma-dark);
|
--luma: var(--subtle-luma-dark);
|
||||||
}
|
}
|
||||||
[color=coral] {
|
[color="coral"] {
|
||||||
--hue: 20;
|
--hue: 20;
|
||||||
--accent-luma: 50%;
|
--accent-luma: 50%;
|
||||||
--accent-luma-dark: 70%;
|
--accent-luma-dark: 70%;
|
||||||
@@ -87,7 +85,7 @@ body[theme=dark] [color]:not([color=standard]).subtle-background {
|
|||||||
--subtle-luma: 95%;
|
--subtle-luma: 95%;
|
||||||
--subtle-luma-dark: 5%;
|
--subtle-luma-dark: 5%;
|
||||||
}
|
}
|
||||||
[color=yellow] {
|
[color="yellow"] {
|
||||||
--hue: 50;
|
--hue: 50;
|
||||||
--accent-luma: 50%;
|
--accent-luma: 50%;
|
||||||
--accent-luma-dark: 60%;
|
--accent-luma-dark: 60%;
|
||||||
@@ -98,7 +96,7 @@ body[theme=dark] [color]:not([color=standard]).subtle-background {
|
|||||||
--subtle-luma: 95%;
|
--subtle-luma: 95%;
|
||||||
--subtle-luma-dark: 5%;
|
--subtle-luma-dark: 5%;
|
||||||
}
|
}
|
||||||
[color=green] {
|
[color="green"] {
|
||||||
--hue: 120;
|
--hue: 120;
|
||||||
--accent-luma: 40%;
|
--accent-luma: 40%;
|
||||||
--accent-luma-dark: 60%;
|
--accent-luma-dark: 60%;
|
||||||
@@ -109,7 +107,7 @@ body[theme=dark] [color]:not([color=standard]).subtle-background {
|
|||||||
--subtle-luma: 95%;
|
--subtle-luma: 95%;
|
||||||
--subtle-luma-dark: 5%;
|
--subtle-luma-dark: 5%;
|
||||||
}
|
}
|
||||||
[color=lightblue] {
|
[color="lightblue"] {
|
||||||
--hue: 180;
|
--hue: 180;
|
||||||
--accent-luma: 40%;
|
--accent-luma: 40%;
|
||||||
--accent-luma-dark: 60%;
|
--accent-luma-dark: 60%;
|
||||||
@@ -120,7 +118,7 @@ body[theme=dark] [color]:not([color=standard]).subtle-background {
|
|||||||
--subtle-luma: 95%;
|
--subtle-luma: 95%;
|
||||||
--subtle-luma-dark: 5%;
|
--subtle-luma-dark: 5%;
|
||||||
}
|
}
|
||||||
[color=blue] {
|
[color="blue"] {
|
||||||
--hue: 220;
|
--hue: 220;
|
||||||
--accent-luma: 50%;
|
--accent-luma: 50%;
|
||||||
--accent-luma-dark: 70%;
|
--accent-luma-dark: 70%;
|
||||||
@@ -131,7 +129,7 @@ body[theme=dark] [color]:not([color=standard]).subtle-background {
|
|||||||
--subtle-luma: 95%;
|
--subtle-luma: 95%;
|
||||||
--subtle-luma-dark: 5%;
|
--subtle-luma-dark: 5%;
|
||||||
}
|
}
|
||||||
[color=purple] {
|
[color="purple"] {
|
||||||
--hue: 280;
|
--hue: 280;
|
||||||
--accent-luma: 50%;
|
--accent-luma: 50%;
|
||||||
--accent-luma-dark: 70%;
|
--accent-luma-dark: 70%;
|
||||||
@@ -205,35 +203,35 @@ main {
|
|||||||
#background-wrapper #grass-1 {
|
#background-wrapper #grass-1 {
|
||||||
--color-1: hsl(150, 100%, 30%);
|
--color-1: hsl(150, 100%, 30%);
|
||||||
--color-2: hsl(150, 100%, 25%);
|
--color-2: hsl(150, 100%, 25%);
|
||||||
background-image:
|
background-image: linear-gradient(
|
||||||
linear-gradient(
|
|
||||||
350deg,
|
350deg,
|
||||||
var(--color-1),
|
var(--color-1),
|
||||||
var(--color-2) 30%,
|
var(--color-2) 30%,
|
||||||
transparent 40%);
|
transparent 40%
|
||||||
|
);
|
||||||
}
|
}
|
||||||
#background-wrapper #grass-2 {
|
#background-wrapper #grass-2 {
|
||||||
--color-1: hsl(110, 100%, 40%);
|
--color-1: hsl(110, 100%, 40%);
|
||||||
--color-2: hsl(110, 100%, 35%);
|
--color-2: hsl(110, 100%, 35%);
|
||||||
background-image:
|
background-image: linear-gradient(
|
||||||
linear-gradient(
|
|
||||||
9deg,
|
9deg,
|
||||||
var(--color-1),
|
var(--color-1),
|
||||||
var(--color-2) 30%,
|
var(--color-2) 30%,
|
||||||
transparent 35%);
|
transparent 35%
|
||||||
|
);
|
||||||
}
|
}
|
||||||
body[theme=dark] #background-wrapper {
|
body[theme="dark"] #background-wrapper {
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
}
|
}
|
||||||
body[theme=dark] #background-wrapper #sky {
|
body[theme="dark"] #background-wrapper #sky {
|
||||||
--color-1: hsl(188, 100%, 30%);
|
--color-1: hsl(188, 100%, 30%);
|
||||||
--color-2: hsl(194, 72%, 24%);
|
--color-2: hsl(194, 72%, 24%);
|
||||||
}
|
}
|
||||||
body[theme=dark] #background-wrapper #grass-1 {
|
body[theme="dark"] #background-wrapper #grass-1 {
|
||||||
--color-1: hsl(120, 30%, 30%);
|
--color-1: hsl(120, 30%, 30%);
|
||||||
--color-2: hsl(120, 30%, 24%);
|
--color-2: hsl(120, 30%, 24%);
|
||||||
}
|
}
|
||||||
body[theme=dark] #background-wrapper #grass-2 {
|
body[theme="dark"] #background-wrapper #grass-2 {
|
||||||
--color-1: hsl(110, 60%, 30%);
|
--color-1: hsl(110, 60%, 30%);
|
||||||
--color-2: hsl(110, 50%, 24%);
|
--color-2: hsl(110, 50%, 24%);
|
||||||
}
|
}
|
||||||
@@ -264,7 +262,9 @@ body[theme=dark] #background-wrapper #grass-2 {
|
|||||||
}
|
}
|
||||||
#home-page #overview-section,
|
#home-page #overview-section,
|
||||||
#home-page #chat-section {
|
#home-page #chat-section {
|
||||||
padding-bottom: calc(var(--content-padding) + var(--header-height) + var(--safe-area-bottom));
|
padding-bottom: calc(
|
||||||
|
var(--content-padding) + var(--header-height) + var(--safe-area-bottom)
|
||||||
|
);
|
||||||
}
|
}
|
||||||
#home-page #chat-grid {
|
#home-page #chat-grid {
|
||||||
margin-top: var(--content-padding);
|
margin-top: var(--content-padding);
|
||||||
@@ -387,7 +387,14 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
padding-bottom: var(--safe-area-bottom);
|
padding-bottom: var(--safe-area-bottom);
|
||||||
}
|
}
|
||||||
#chat-page > div > #ribbon > span,
|
#chat-page > div > #ribbon > span,
|
||||||
#chat-page > div > #main > div > .pane-wrapper > .pane > .toolbar > span.ribbon {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> div
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
> span.ribbon {
|
||||||
gap: var(--gap-between-tiles);
|
gap: var(--gap-between-tiles);
|
||||||
padding: var(--gap-between-tiles);
|
padding: var(--gap-between-tiles);
|
||||||
}
|
}
|
||||||
@@ -438,7 +445,14 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
}
|
}
|
||||||
#chat-page > div > #ribbon button.ribbon-button,
|
#chat-page > div > #ribbon button.ribbon-button,
|
||||||
#chat-page > div > #main > div > .pane-wrapper > .pane > .toolbar button.ribbon-button {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> div
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
button.ribbon-button {
|
||||||
min-width: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
min-width: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
||||||
width: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
width: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
||||||
max-width: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
max-width: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
||||||
@@ -447,7 +461,15 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
color: var(--primary);
|
color: var(--primary);
|
||||||
}
|
}
|
||||||
#chat-page > div > #ribbon button > .icon,
|
#chat-page > div > #ribbon button > .icon,
|
||||||
#chat-page > div > #main > div > .pane-wrapper > .pane > .toolbar button > .icon {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> div
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
button
|
||||||
|
> .icon {
|
||||||
font-size: 1.1rem;
|
font-size: 1.1rem;
|
||||||
}
|
}
|
||||||
#chat-page > div > #ribbon > span {
|
#chat-page > div > #ribbon > span {
|
||||||
@@ -465,7 +487,14 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
#chat-page > div > #main > div > .pane-wrapper > .pane > .toolbar > span.title {
|
#chat-page > div > #main > div > .pane-wrapper > .pane > .toolbar > span.title {
|
||||||
padding-left: var(--content-padding);
|
padding-left: var(--content-padding);
|
||||||
}
|
}
|
||||||
#chat-page > div > #main > div > .pane-wrapper > .pane > .toolbar :is(input, select, button) {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> div
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
:is(input, select, button) {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
}
|
}
|
||||||
@@ -476,7 +505,14 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
padding: 0px;
|
padding: 0px;
|
||||||
}
|
}
|
||||||
#chat-page > div > #main > #task-page > .pane-wrapper > .pane > .main-content > div {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> #task-page
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .main-content
|
||||||
|
> div {
|
||||||
animation: slide-up var(--animation-duration);
|
animation: slide-up var(--animation-duration);
|
||||||
}
|
}
|
||||||
#chat-page > div > #main > #task-page .task-grid {
|
#chat-page > div > #main > #task-page .task-grid {
|
||||||
@@ -533,7 +569,11 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
#chat-page > div > #main > #task-page .board-toggle-button {
|
#chat-page > div > #main > #task-page .board-toggle-button {
|
||||||
display: flex;
|
display: flex;
|
||||||
}
|
}
|
||||||
#chat-page > div > #main > #task-page[isshowingboard][showingboardlist=false] #board-list {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> #task-page[isshowingboard][showingboardlist="false"]
|
||||||
|
#board-list {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
@media (min-width: 640px) {
|
@media (min-width: 640px) {
|
||||||
@@ -572,10 +612,18 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
}
|
}
|
||||||
#chat-page #main #message-page .content #message-container {
|
#chat-page #main #message-page .content #message-container {
|
||||||
--message-container-padding: var(--control-height);
|
--message-container-padding: var(--control-height);
|
||||||
padding-bottom: calc(var(--message-container-padding) + var(--content-padding)) !important;
|
padding-bottom: calc(
|
||||||
|
var(--message-container-padding) + var(--content-padding)
|
||||||
|
) !important;
|
||||||
}
|
}
|
||||||
#chat-page #main #message-page .content:has(.reply-preview-wrapper .reply-preview) #message-container {
|
#chat-page
|
||||||
--message-container-padding: calc( 2 * var(--control-height) + var(--gap-between-tiles) );
|
#main
|
||||||
|
#message-page
|
||||||
|
.content:has(.reply-preview-wrapper .reply-preview)
|
||||||
|
#message-container {
|
||||||
|
--message-container-padding: calc(
|
||||||
|
2 * var(--control-height) + var(--gap-between-tiles)
|
||||||
|
);
|
||||||
}
|
}
|
||||||
#message-page #message-container {
|
#message-page #message-container {
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
@@ -789,12 +837,27 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* src/View/ChatPages/calendarPage.css */
|
/* src/View/ChatPages/calendarPage.css */
|
||||||
#chat-page > div > #main > #calendar-page > .pane-wrapper > .pane > .toolbar .input-wrapper {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> #calendar-page
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
.input-wrapper {
|
||||||
display: flex;
|
display: flex;
|
||||||
padding: var(--gap-between-tiles);
|
padding: var(--gap-between-tiles);
|
||||||
gap: var(--gap-between-tiles);
|
gap: var(--gap-between-tiles);
|
||||||
}
|
}
|
||||||
#chat-page > div > #main > #calendar-page > .pane-wrapper > .pane > .toolbar .input-wrapper > input {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> #calendar-page
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
.input-wrapper
|
||||||
|
> input {
|
||||||
min-height: unset;
|
min-height: unset;
|
||||||
height: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
height: calc(var(--control-height) - 2 * var(--gap-between-tiles));
|
||||||
appearance: textfield;
|
appearance: textfield;
|
||||||
@@ -807,10 +870,26 @@ body[showing-chat] #chat-page-wrapper {
|
|||||||
-webkit-appearance: none;
|
-webkit-appearance: none;
|
||||||
margin: 0px;
|
margin: 0px;
|
||||||
}
|
}
|
||||||
#chat-page > div > #main > #calendar-page > .pane-wrapper > .pane > .toolbar .input-wrapper > .year-input {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> #calendar-page
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
.input-wrapper
|
||||||
|
> .year-input {
|
||||||
width: 4.4rem;
|
width: 4.4rem;
|
||||||
}
|
}
|
||||||
#chat-page > div > #main > #calendar-page > .pane-wrapper > .pane > .toolbar .input-wrapper > .month-input {
|
#chat-page
|
||||||
|
> div
|
||||||
|
> #main
|
||||||
|
> #calendar-page
|
||||||
|
> .pane-wrapper
|
||||||
|
> .pane
|
||||||
|
> .toolbar
|
||||||
|
.input-wrapper
|
||||||
|
> .month-input {
|
||||||
width: 3.1rem;
|
width: 3.1rem;
|
||||||
}
|
}
|
||||||
@media (max-width: 750px) {
|
@media (max-width: 750px) {
|
||||||
|
|||||||
Vendored
+3974
-1607
File diff suppressed because it is too large
Load Diff
Vendored
+33
-12
@@ -65,7 +65,11 @@ body {
|
|||||||
--text-error: #da1e28;
|
--text-error: #da1e28;
|
||||||
--text-info: #0043ce;
|
--text-info: #0043ce;
|
||||||
|
|
||||||
--highlight-background: linear-gradient(45deg, hsl(30, 100%, 50%), hsl(40, 100%, 50%));
|
--highlight-background: linear-gradient(
|
||||||
|
45deg,
|
||||||
|
hsl(30, 100%, 50%),
|
||||||
|
hsl(40, 100%, 50%)
|
||||||
|
);
|
||||||
--highlight-color: black;
|
--highlight-color: black;
|
||||||
|
|
||||||
--link: #0f62fe;
|
--link: #0f62fe;
|
||||||
@@ -366,7 +370,9 @@ footer {
|
|||||||
border-top: 1px solid var(--surface-border);
|
border-top: 1px solid var(--surface-border);
|
||||||
}
|
}
|
||||||
|
|
||||||
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not(label.tile *),
|
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not(
|
||||||
|
label.tile *
|
||||||
|
),
|
||||||
label.tile,
|
label.tile,
|
||||||
select:not(label.tile *),
|
select:not(label.tile *),
|
||||||
textarea:not(label.tile *) {
|
textarea:not(label.tile *) {
|
||||||
@@ -381,7 +387,9 @@ hr {
|
|||||||
border-bottom: 1px solid var(--border) !important;
|
border-bottom: 1px solid var(--border) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):focus:not(label.tile *):not(.no-outline),
|
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):focus:not(
|
||||||
|
label.tile *
|
||||||
|
):not(.no-outline),
|
||||||
label.tile:has(input:focus),
|
label.tile:has(input:focus),
|
||||||
label.tile:has(textarea:focus),
|
label.tile:has(textarea:focus),
|
||||||
textarea:focus:not(label.tile *),
|
textarea:focus:not(label.tile *),
|
||||||
@@ -701,7 +709,10 @@ select {
|
|||||||
}
|
}
|
||||||
|
|
||||||
article > div {
|
article > div {
|
||||||
padding-bottom: calc(var(--menu-height-mobile) + var(--control-height) + var(--content-padding));
|
padding-bottom: calc(
|
||||||
|
var(--menu-height-mobile) + var(--control-height) +
|
||||||
|
var(--content-padding)
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
label:not(.inline) {
|
label:not(.inline) {
|
||||||
@@ -1049,7 +1060,10 @@ menu {
|
|||||||
}
|
}
|
||||||
|
|
||||||
article > div {
|
article > div {
|
||||||
padding-bottom: calc(var(--menu-height-mobile) + var(--header-height) + var(--content-padding));
|
padding-bottom: calc(
|
||||||
|
var(--menu-height-mobile) + var(--header-height) +
|
||||||
|
var(--content-padding)
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* overflow */
|
/* overflow */
|
||||||
@@ -1135,7 +1149,6 @@ main {
|
|||||||
|
|
||||||
/* tablet & up */
|
/* tablet & up */
|
||||||
@media (min-width: 640px) {
|
@media (min-width: 640px) {
|
||||||
|
|
||||||
/* basic */
|
/* basic */
|
||||||
.mobile-only {
|
.mobile-only {
|
||||||
display: none !important;
|
display: none !important;
|
||||||
@@ -1234,11 +1247,13 @@ STATE
|
|||||||
}
|
}
|
||||||
|
|
||||||
@keyframes highlight {
|
@keyframes highlight {
|
||||||
30%, 60% {
|
30%,
|
||||||
|
60% {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
0%, 100% {
|
0%,
|
||||||
opacity: .1;
|
100% {
|
||||||
|
opacity: 0.1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1247,11 +1262,17 @@ STATE
|
|||||||
}
|
}
|
||||||
|
|
||||||
@keyframes scroll-highlight {
|
@keyframes scroll-highlight {
|
||||||
0%, 40%, 50%, 90% {
|
0%,
|
||||||
|
40%,
|
||||||
|
50%,
|
||||||
|
90% {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
10%, 30%, 60%, 80% {
|
10%,
|
||||||
opacity: .5;
|
30%,
|
||||||
|
60%,
|
||||||
|
80% {
|
||||||
|
opacity: 0.5;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -57,7 +57,10 @@ export default class BoardsAndTasksModel {
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly getTaskReferencePath = (boardId: string, fileId: string): string[] => {
|
readonly getTaskReferencePath = (
|
||||||
|
boardId: string,
|
||||||
|
fileId: string,
|
||||||
|
): string[] => {
|
||||||
return [...this.getTaskContainerPath(boardId), fileId];
|
return [...this.getTaskContainerPath(boardId), fileId];
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -99,17 +102,23 @@ export default class BoardsAndTasksModel {
|
|||||||
return boardInfoFileContent;
|
return boardInfoFileContent;
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly updateBoard = (boardInfoFileContent: BoardInfoFileContent): void => {
|
readonly updateBoard = (
|
||||||
|
boardInfoFileContent: BoardInfoFileContent,
|
||||||
|
): void => {
|
||||||
this.storeBoard(boardInfoFileContent);
|
this.storeBoard(boardInfoFileContent);
|
||||||
this.boardHandlerManager.trigger(boardInfoFileContent);
|
this.boardHandlerManager.trigger(boardInfoFileContent);
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly updateBoardAndSend = (boardInfoFileContent: BoardInfoFileContent): void => {
|
readonly updateBoardAndSend = (
|
||||||
|
boardInfoFileContent: BoardInfoFileContent,
|
||||||
|
): void => {
|
||||||
this.updateBoard(boardInfoFileContent);
|
this.updateBoard(boardInfoFileContent);
|
||||||
this.chatModel.sendMessage("", undefined, boardInfoFileContent);
|
this.chatModel.sendMessage("", undefined, boardInfoFileContent);
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly storeBoard = (boardInfoFileContent: BoardInfoFileContent): void => {
|
readonly storeBoard = (
|
||||||
|
boardInfoFileContent: BoardInfoFileContent,
|
||||||
|
): void => {
|
||||||
// store info
|
// store info
|
||||||
this.fileModel.storeFileContent(boardInfoFileContent);
|
this.fileModel.storeFileContent(boardInfoFileContent);
|
||||||
|
|
||||||
@@ -194,7 +203,9 @@ export default class BoardsAndTasksModel {
|
|||||||
return versionIds;
|
return versionIds;
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly getLatestTaskFileContent = (taskId: string): TaskFileContent | null => {
|
readonly getLatestTaskFileContent = (
|
||||||
|
taskId: string,
|
||||||
|
): TaskFileContent | null => {
|
||||||
const taskFileContentOrNull: TaskFileContent | null =
|
const taskFileContentOrNull: TaskFileContent | null =
|
||||||
this.fileModel.getLatestFileContent(
|
this.fileModel.getLatestFileContent(
|
||||||
taskId,
|
taskId,
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ export default class CalendarModel {
|
|||||||
return this.fileModel.getModelContainerPath(
|
return this.fileModel.getModelContainerPath(
|
||||||
FileModelSubPath.ModelCalendar,
|
FileModelSubPath.ModelCalendar,
|
||||||
);
|
);
|
||||||
};
|
}
|
||||||
|
|
||||||
readonly getViewPath = (): string[] => {
|
readonly getViewPath = (): string[] => {
|
||||||
return [...this.basePath, FileModelSubPath.ModelView];
|
return [...this.basePath, FileModelSubPath.ModelView];
|
||||||
@@ -44,7 +44,10 @@ export default class CalendarModel {
|
|||||||
this.storageModel.write(referencePath, "");
|
this.storageModel.write(referencePath, "");
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly deleteTaskReference = (monthString: string, taskId: string): void => {
|
readonly deleteTaskReference = (
|
||||||
|
monthString: string,
|
||||||
|
taskId: string,
|
||||||
|
): void => {
|
||||||
const monthPath: string[] = this.getMonthPath(monthString);
|
const monthPath: string[] = this.getMonthPath(monthString);
|
||||||
const referencePath: string[] = [...monthPath, taskId];
|
const referencePath: string[] = [...monthPath, taskId];
|
||||||
|
|
||||||
|
|||||||
@@ -29,13 +29,15 @@ export default class FileModel {
|
|||||||
StorageModelSubPaths.Chat,
|
StorageModelSubPaths.Chat,
|
||||||
filePaths.chat.files(this.chatModel.id),
|
filePaths.chat.files(this.chatModel.id),
|
||||||
);
|
);
|
||||||
};
|
}
|
||||||
|
|
||||||
readonly getFileContainerPath = (): string[] => {
|
readonly getFileContainerPath = (): string[] => {
|
||||||
return [...this.basePath, FileModelSubPath.Data];
|
return [...this.basePath, FileModelSubPath.Data];
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly getModelContainerPath = (modelName: FileModelSubPath): string[] => {
|
readonly getModelContainerPath = (
|
||||||
|
modelName: FileModelSubPath,
|
||||||
|
): string[] => {
|
||||||
return [...this.basePath, FileModelSubPath.Model, modelName];
|
return [...this.basePath, FileModelSubPath.Model, modelName];
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -43,13 +45,18 @@ export default class FileModel {
|
|||||||
return [...this.getFileContainerPath(), fileId];
|
return [...this.getFileContainerPath(), fileId];
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly getFileContentPath = (fileId: string, fileContentId: string): string[] => {
|
readonly getFileContentPath = (
|
||||||
|
fileId: string,
|
||||||
|
fileContentId: string,
|
||||||
|
): string[] => {
|
||||||
const filePath: string[] = this.getFilePath(fileId);
|
const filePath: string[] = this.getFilePath(fileId);
|
||||||
return [...filePath, fileContentId];
|
return [...filePath, fileContentId];
|
||||||
};
|
};
|
||||||
|
|
||||||
// handlers
|
// handlers
|
||||||
readonly handleStringifiedFileContent = (stringifiedFileContent: string): void => {
|
readonly handleStringifiedFileContent = (
|
||||||
|
stringifiedFileContent: string,
|
||||||
|
): void => {
|
||||||
const fileContent: FileContent<string> | null = parseValidObject(
|
const fileContent: FileContent<string> | null = parseValidObject(
|
||||||
stringifiedFileContent,
|
stringifiedFileContent,
|
||||||
FileContentReference,
|
FileContentReference,
|
||||||
@@ -68,7 +75,9 @@ export default class FileModel {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// methods
|
// methods
|
||||||
readonly addFileContentAndSend = (fileContent: FileContent<string>): void => {
|
readonly addFileContentAndSend = (
|
||||||
|
fileContent: FileContent<string>,
|
||||||
|
): void => {
|
||||||
this.handleFileContent(fileContent);
|
this.handleFileContent(fileContent);
|
||||||
this.chatModel.sendMessage("", undefined, fileContent);
|
this.chatModel.sendMessage("", undefined, fileContent);
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -69,7 +69,9 @@ export default class FileTransferModel {
|
|||||||
this.handleTransferredFile(data.messageBody);
|
this.handleTransferredFile(data.messageBody);
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly handleTransferredFile = async (encryptedFileData: string): Promise<void> => {
|
readonly handleTransferredFile = async (
|
||||||
|
encryptedFileData: string,
|
||||||
|
): Promise<void> => {
|
||||||
if (this.transferData == undefined) return;
|
if (this.transferData == undefined) return;
|
||||||
|
|
||||||
const decrypted: string = await decryptString(
|
const decrypted: string = await decryptString(
|
||||||
@@ -80,6 +82,19 @@ export default class FileTransferModel {
|
|||||||
this.handleDecryptedFile(decrypted);
|
this.handleDecryptedFile(decrypted);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
readonly handleBackupFile = async (encryptedBackup: string, passphrase: string): Promise<void> => {
|
||||||
|
const decrypted: string = await decryptString(encryptedBackup, passphrase);
|
||||||
|
const parsed = parse(decrypted);
|
||||||
|
if (!Array.isArray(parsed)) {
|
||||||
|
console.error("Canceling backup - not an array", decrypted);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
for (const file of parsed) {
|
||||||
|
this.handleDecryptedFile(file);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
readonly handleDecryptedFile = (data: string): void => {
|
readonly handleDecryptedFile = (data: string): void => {
|
||||||
const parsed: any = parse(data);
|
const parsed: any = parse(data);
|
||||||
const isFileData: boolean = checkMatchesObjectStructure(
|
const isFileData: boolean = checkMatchesObjectStructure(
|
||||||
@@ -95,25 +110,40 @@ export default class FileTransferModel {
|
|||||||
...fileData.path,
|
...fileData.path,
|
||||||
);
|
);
|
||||||
this.fileHandlerManager.trigger(pathString);
|
this.fileHandlerManager.trigger(pathString);
|
||||||
}
|
};
|
||||||
|
|
||||||
// sending
|
// sending
|
||||||
readonly sendFiles = (
|
readonly sendFiles = (
|
||||||
directoryPaths: IteratorObject<string[]>,
|
directoryPaths: IteratorObject<string[]>,
|
||||||
callback: (path: string) => void,
|
fileCallback: (path: string) => void,
|
||||||
): void => {
|
): void => {
|
||||||
for (const directoryPath of directoryPaths) {
|
for (const directoryPath of directoryPaths) {
|
||||||
this.storageModel.recurse(directoryPath, (filePath: string[]) => {
|
this.storageModel.recurse(directoryPath, (filePath: string[]) => {
|
||||||
|
const stringifiedFileData =
|
||||||
this.prepareFileForSending(filePath);
|
this.prepareFileForSending(filePath);
|
||||||
|
this.sendFile(stringifiedFileData);
|
||||||
const pathString: string = StorageModel.pathComponentsToString(
|
const pathString: string = StorageModel.pathComponentsToString(
|
||||||
...filePath,
|
...filePath,
|
||||||
);
|
);
|
||||||
callback(pathString);
|
fileCallback(pathString);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly prepareFileForSending = (filePath: string[]): void => {
|
readonly generateBackup = async (directoryPaths: IteratorObject<string[]>, passphrase: string): Promise<string> => {
|
||||||
|
const files: string[] = [];
|
||||||
|
for (const directoryPath of directoryPaths) {
|
||||||
|
this.storageModel.recurse(directoryPath, (filePath: string[]) => {
|
||||||
|
const stringifiedFileData =
|
||||||
|
this.prepareFileForSending(filePath);
|
||||||
|
files.push(stringifiedFileData);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
const rawBackup = stringify(files);
|
||||||
|
return await encryptString(rawBackup, passphrase);
|
||||||
|
};
|
||||||
|
|
||||||
|
readonly prepareFileForSending = (filePath: string[]): string => {
|
||||||
if (this.transferData == undefined) return;
|
if (this.transferData == undefined) return;
|
||||||
const fileContent: string | null = this.storageModel.read(filePath);
|
const fileContent: string | null = this.storageModel.read(filePath);
|
||||||
if (fileContent == null) return;
|
if (fileContent == null) return;
|
||||||
@@ -122,8 +152,7 @@ export default class FileTransferModel {
|
|||||||
path: filePath,
|
path: filePath,
|
||||||
body: fileContent,
|
body: fileContent,
|
||||||
};
|
};
|
||||||
const stringifiedFileData: string = stringify(fileData);
|
return stringify(fileData);
|
||||||
this.sendFile(stringifiedFileData);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
readonly sendFile = async (stringifiedFileData: string): Promise<void> => {
|
readonly sendFile = async (stringifiedFileData: string): Promise<void> => {
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ export default class SettingsModel {
|
|||||||
filePaths.settingsModel[pathName],
|
filePaths.settingsModel[pathName],
|
||||||
);
|
);
|
||||||
this.storageModel.write(path, value);
|
this.storageModel.write(path, value);
|
||||||
}
|
};
|
||||||
|
|
||||||
readonly setName = (newValue: string): void => {
|
readonly setName = (newValue: string): void => {
|
||||||
this.username = newValue;
|
this.username = newValue;
|
||||||
|
|||||||
@@ -69,7 +69,10 @@ export default class StorageModel {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// recursion
|
// recursion
|
||||||
readonly recurse = (rootDirectory: string[], fn: (path: string[]) => void): void => {
|
readonly recurse = (
|
||||||
|
rootDirectory: string[],
|
||||||
|
fn: (path: string[]) => void,
|
||||||
|
): void => {
|
||||||
loop_over_files: for (const key of Object.keys(localStorage)) {
|
loop_over_files: for (const key of Object.keys(localStorage)) {
|
||||||
// get path of current entity
|
// get path of current entity
|
||||||
const pathComponentsOfCurrentEntity: string[] =
|
const pathComponentsOfCurrentEntity: string[] =
|
||||||
|
|||||||
@@ -103,9 +103,7 @@ export function SettingsPage(
|
|||||||
coreViewModel.translations.chatPage.settings
|
coreViewModel.translations.chatPage.settings
|
||||||
.setNamespaceButtonAudioLabel
|
.setNamespaceButtonAudioLabel
|
||||||
}
|
}
|
||||||
on:click={
|
on:click={settingsPageViewModel.setNamespace}
|
||||||
settingsPageViewModel.setNamespace
|
|
||||||
}
|
|
||||||
toggle:disabled={
|
toggle:disabled={
|
||||||
settingsPageViewModel.cannotSetNamespace
|
settingsPageViewModel.cannotSetNamespace
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,8 +20,8 @@ export default class NotificationViewModel {
|
|||||||
if (this.chatListViewModel.selectedChat.value == undefined) return;
|
if (this.chatListViewModel.selectedChat.value == undefined) return;
|
||||||
|
|
||||||
const currentChat =
|
const currentChat =
|
||||||
this.chatListViewModel.selectedChat.value.chatModel.
|
this.chatListViewModel.selectedChat.value.chatModel
|
||||||
unwrappedPrimaryChannel
|
.unwrappedPrimaryChannel;
|
||||||
const currentPage =
|
const currentPage =
|
||||||
this.chatListViewModel.selectedChat.value.selectedPage.value;
|
this.chatListViewModel.selectedChat.value.selectedPage.value;
|
||||||
if (
|
if (
|
||||||
@@ -41,7 +41,8 @@ export default class NotificationViewModel {
|
|||||||
const chat = [
|
const chat = [
|
||||||
...this.chatListViewModel.chatViewModels.value.values(),
|
...this.chatListViewModel.chatViewModels.value.values(),
|
||||||
].find(
|
].find(
|
||||||
(chat) => chat.chatModel.unwrappedPrimaryChannel == notification.chat,
|
(chat) =>
|
||||||
|
chat.chatModel.unwrappedPrimaryChannel == notification.chat,
|
||||||
);
|
);
|
||||||
chat.open();
|
chat.open();
|
||||||
chat.openPage(ChatPageTypes.Messages);
|
chat.openPage(ChatPageTypes.Messages);
|
||||||
|
|||||||
@@ -32,8 +32,7 @@ export default class SettingsPageViewModel extends Context {
|
|||||||
);
|
);
|
||||||
cannotSetNamespace: React.State<boolean> = React.createProxyState(
|
cannotSetNamespace: React.State<boolean> = React.createProxyState(
|
||||||
[this.namespace, this.namespaceInput],
|
[this.namespace, this.namespaceInput],
|
||||||
() =>
|
() => this.namespaceInput.value == this.namespace.value,
|
||||||
this.namespaceInput.value == this.namespace.value,
|
|
||||||
);
|
);
|
||||||
cannotAddSecondaryChannel: React.State<boolean> = React.createProxyState(
|
cannotAddSecondaryChannel: React.State<boolean> = React.createProxyState(
|
||||||
[this.newSecondaryChannelInput],
|
[this.newSecondaryChannelInput],
|
||||||
@@ -53,11 +52,8 @@ export default class SettingsPageViewModel extends Context {
|
|||||||
};
|
};
|
||||||
|
|
||||||
setNamespace = (): void => {
|
setNamespace = (): void => {
|
||||||
this.chatViewModel.chatModel.setNamespace(
|
this.chatViewModel.chatModel.setNamespace(this.namespaceInput.value);
|
||||||
this.namespaceInput.value,
|
this.namespace.value = this.chatViewModel.chatModel.info.namespace;
|
||||||
);
|
|
||||||
this.namespace.value =
|
|
||||||
this.chatViewModel.chatModel.info.namespace;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
addSecondaryChannel = (): void => {
|
addSecondaryChannel = (): void => {
|
||||||
@@ -101,17 +97,14 @@ export default class SettingsPageViewModel extends Context {
|
|||||||
preloadData = (): void => {
|
preloadData = (): void => {
|
||||||
this.primaryChannel.value =
|
this.primaryChannel.value =
|
||||||
this.chatViewModel.chatModel.info.primaryChannel;
|
this.chatViewModel.chatModel.info.primaryChannel;
|
||||||
this.namespace.value =
|
this.namespace.value = this.chatViewModel.chatModel.info.namespace;
|
||||||
this.chatViewModel.chatModel.info.namespace;
|
|
||||||
|
|
||||||
this.color.value = this.chatViewModel.chatModel.color;
|
this.color.value = this.chatViewModel.chatModel.color;
|
||||||
};
|
};
|
||||||
|
|
||||||
loadData = (): void => {
|
loadData = (): void => {
|
||||||
this.primaryChannelInput.value =
|
this.primaryChannelInput.value = this.primaryChannel.value;
|
||||||
this.primaryChannel.value;
|
this.namespaceInput.value = this.namespace.value;
|
||||||
this.namespaceInput.value =
|
|
||||||
this.namespace.value;
|
|
||||||
|
|
||||||
this.loadSecondaryChannels();
|
this.loadSecondaryChannels();
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -5,6 +5,6 @@
|
|||||||
"jsxFactory": "React.createElement",
|
"jsxFactory": "React.createElement",
|
||||||
"moduleResolution": "node",
|
"moduleResolution": "node",
|
||||||
"esModuleInterop": true,
|
"esModuleInterop": true,
|
||||||
"target": "es2020",
|
"target": "es2020"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user