├── .gitignore ├── .hgignore ├── Procfile ├── README.md ├── app.conf ├── artwork ├── logo.png └── logo.svg ├── config.py ├── config.yaml ├── docs ├── Makefile ├── _themes │ ├── LICENSE │ ├── README │ ├── flask │ │ ├── layout.html │ │ ├── relations.html │ │ ├── static │ │ │ └── flasky.css_t │ │ └── theme.conf │ ├── flask_small │ │ ├── layout.html │ │ ├── static │ │ │ └── flasky.css_t │ │ └── theme.conf │ └── flask_theme_support.py ├── conf.py ├── index.rst ├── installation.rst ├── make.bat ├── models.rst └── templating.rst ├── index.py ├── index.wsgi ├── init_db.py ├── manage.py ├── migrations ├── README ├── alembic.ini ├── env.py ├── script.py.mako └── versions │ ├── 1039e4baf2c8_.py │ ├── 13039747aa3_.py │ └── 573c11d104ad_.py ├── mydeps ├── flask_restless │ ├── __init__.py │ ├── helpers.py │ └── search.py ├── flask_themes.py └── mdx_joinline.py ├── requirements.txt ├── requirements ├── bae3.txt ├── common.txt ├── dev.txt └── jae.txt ├── runserver.bat ├── runserver.sh ├── schema.sql ├── tests ├── __init__.py ├── test_basics.py ├── test_search.py └── test_user_model.py ├── wsgi.py └── wtxlog ├── __init__.py ├── account ├── __init__.py ├── forms.py ├── templates │ ├── base.html │ ├── change_email.html │ ├── change_password.html │ ├── email │ │ ├── change_email.html │ │ ├── change_email.txt │ │ ├── confirm.html │ │ ├── confirm.txt │ │ ├── reset_password.html │ │ └── reset_password.txt │ ├── index.html │ ├── login.html │ ├── register.html │ └── reset_password.html └── views.py ├── admins.py ├── api ├── __init__.py └── views.py ├── babel ├── babel.ini ├── tr_compile.py ├── tr_init.py └── tr_update.py ├── decorators.py ├── ext.py ├── main ├── __init__.py ├── errors.py └── views.py ├── models.py ├── static ├── admin │ ├── admin │ │ ├── css │ │ │ ├── admin.css │ │ │ └── rediscli.css │ │ └── js │ │ │ ├── actions.js │ │ │ ├── filters.js │ │ │ ├── form.js │ │ │ └── rediscli.js │ ├── bootstrap │ │ ├── css │ │ │ ├── bootstrap-responsive.css │ │ │ ├── bootstrap-responsive.min.css │ │ │ ├── bootstrap.css │ │ │ └── bootstrap.min.css │ │ ├── img │ │ │ ├── glyphicons-halflings-white.png │ │ │ └── glyphicons-halflings.png │ │ └── js │ │ │ ├── bootstrap.js │ │ │ └── bootstrap.min.js │ ├── ckeditor │ │ ├── ckeditor.js │ │ ├── config.js │ │ ├── contents.css │ │ ├── lang │ │ │ ├── en.js │ │ │ ├── zh-cn.js │ │ │ └── zh.js │ │ ├── plugins │ │ │ ├── a11yhelp │ │ │ │ └── dialogs │ │ │ │ │ ├── a11yhelp.js │ │ │ │ │ └── lang │ │ │ │ │ ├── _translationstatus.txt │ │ │ │ │ ├── ar.js │ │ │ │ │ ├── bg.js │ │ │ │ │ ├── ca.js │ │ │ │ │ ├── cs.js │ │ │ │ │ ├── cy.js │ │ │ │ │ ├── da.js │ │ │ │ │ ├── de.js │ │ │ │ │ ├── el.js │ │ │ │ │ ├── en-gb.js │ │ │ │ │ ├── en.js │ │ │ │ │ ├── eo.js │ │ │ │ │ ├── es.js │ │ │ │ │ ├── et.js │ │ │ │ │ ├── fa.js │ │ │ │ │ ├── fi.js │ │ │ │ │ ├── fr-ca.js │ │ │ │ │ ├── fr.js │ │ │ │ │ ├── gl.js │ │ │ │ │ ├── gu.js │ │ │ │ │ ├── he.js │ │ │ │ │ ├── hi.js │ │ │ │ │ ├── hr.js │ │ │ │ │ ├── hu.js │ │ │ │ │ ├── id.js │ │ │ │ │ ├── it.js │ │ │ │ │ ├── ja.js │ │ │ │ │ ├── km.js │ │ │ │ │ ├── ko.js │ │ │ │ │ ├── ku.js │ │ │ │ │ ├── lt.js │ │ │ │ │ ├── lv.js │ │ │ │ │ ├── mk.js │ │ │ │ │ ├── mn.js │ │ │ │ │ ├── nb.js │ │ │ │ │ ├── nl.js │ │ │ │ │ ├── no.js │ │ │ │ │ ├── pl.js │ │ │ │ │ ├── pt-br.js │ │ │ │ │ ├── pt.js │ │ │ │ │ ├── ro.js │ │ │ │ │ ├── ru.js │ │ │ │ │ ├── si.js │ │ │ │ │ ├── sk.js │ │ │ │ │ ├── sl.js │ │ │ │ │ ├── sq.js │ │ │ │ │ ├── sr-latn.js │ │ │ │ │ ├── sr.js │ │ │ │ │ ├── sv.js │ │ │ │ │ ├── th.js │ │ │ │ │ ├── tr.js │ │ │ │ │ ├── tt.js │ │ │ │ │ ├── ug.js │ │ │ │ │ ├── uk.js │ │ │ │ │ ├── vi.js │ │ │ │ │ ├── zh-cn.js │ │ │ │ │ └── zh.js │ │ │ ├── about │ │ │ │ └── dialogs │ │ │ │ │ ├── about.js │ │ │ │ │ ├── hidpi │ │ │ │ │ └── logo_ckeditor.png │ │ │ │ │ └── logo_ckeditor.png │ │ │ ├── clipboard │ │ │ │ └── dialogs │ │ │ │ │ └── paste.js │ │ │ ├── colorbutton │ │ │ │ ├── icons │ │ │ │ │ ├── bgcolor.png │ │ │ │ │ ├── hidpi │ │ │ │ │ │ ├── bgcolor.png │ │ │ │ │ │ └── textcolor.png │ │ │ │ │ └── textcolor.png │ │ │ │ ├── lang │ │ │ │ │ ├── en.js │ │ │ │ │ ├── zh-cn.js │ │ │ │ │ └── zh.js │ │ │ │ └── plugin.js │ │ │ ├── colordialog │ │ │ │ ├── dialogs │ │ │ │ │ └── colordialog.js │ │ │ │ ├── lang │ │ │ │ │ ├── en.js │ │ │ │ │ └── zh-cn.js │ │ │ │ └── plugin.js │ │ │ ├── dialog │ │ │ │ └── dialogDefinition.js │ │ │ ├── fakeobjects │ │ │ │ └── images │ │ │ │ │ └── spacer.gif │ │ │ ├── floatpanel │ │ │ │ └── plugin.js │ │ │ ├── font │ │ │ │ ├── lang │ │ │ │ │ ├── en.js │ │ │ │ │ └── zh-cn.js │ │ │ │ └── plugin.js │ │ │ ├── icons.png │ │ │ ├── icons_hidpi.png │ │ │ ├── image │ │ │ │ ├── dialogs │ │ │ │ │ └── image.js │ │ │ │ └── images │ │ │ │ │ └── noimage.png │ │ │ ├── justify │ │ │ │ ├── icons │ │ │ │ │ ├── hidpi │ │ │ │ │ │ ├── justifyblock.png │ │ │ │ │ │ ├── justifycenter.png │ │ │ │ │ │ ├── justifyleft.png │ │ │ │ │ │ └── justifyright.png │ │ │ │ │ ├── justifyblock.png │ │ │ │ │ ├── justifycenter.png │ │ │ │ │ ├── justifyleft.png │ │ │ │ │ └── justifyright.png │ │ │ │ ├── lang │ │ │ │ │ ├── en.js │ │ │ │ │ └── zh-cn.js │ │ │ │ └── plugin.js │ │ │ ├── link │ │ │ │ ├── dialogs │ │ │ │ │ ├── anchor.js │ │ │ │ │ └── link.js │ │ │ │ └── images │ │ │ │ │ ├── anchor.png │ │ │ │ │ └── hidpi │ │ │ │ │ └── anchor.png │ │ │ ├── magicline │ │ │ │ └── images │ │ │ │ │ ├── hidpi │ │ │ │ │ └── icon.png │ │ │ │ │ └── icon.png │ │ │ ├── panelbutton │ │ │ │ └── plugin.js │ │ │ ├── pastefromword │ │ │ │ └── filter │ │ │ │ │ └── default.js │ │ │ ├── scayt │ │ │ │ ├── LICENSE.md │ │ │ │ ├── README.md │ │ │ │ └── dialogs │ │ │ │ │ ├── options.js │ │ │ │ │ └── toolbar.css │ │ │ ├── specialchar │ │ │ │ └── dialogs │ │ │ │ │ ├── lang │ │ │ │ │ ├── _translationstatus.txt │ │ │ │ │ ├── ar.js │ │ │ │ │ ├── bg.js │ │ │ │ │ ├── ca.js │ │ │ │ │ ├── cs.js │ │ │ │ │ ├── cy.js │ │ │ │ │ ├── de.js │ │ │ │ │ ├── el.js │ │ │ │ │ ├── en-gb.js │ │ │ │ │ ├── en.js │ │ │ │ │ ├── eo.js │ │ │ │ │ ├── es.js │ │ │ │ │ ├── et.js │ │ │ │ │ ├── fa.js │ │ │ │ │ ├── fi.js │ │ │ │ │ ├── fr-ca.js │ │ │ │ │ ├── fr.js │ │ │ │ │ ├── gl.js │ │ │ │ │ ├── he.js │ │ │ │ │ ├── hr.js │ │ │ │ │ ├── hu.js │ │ │ │ │ ├── id.js │ │ │ │ │ ├── it.js │ │ │ │ │ ├── ja.js │ │ │ │ │ ├── km.js │ │ │ │ │ ├── ku.js │ │ │ │ │ ├── lv.js │ │ │ │ │ ├── nb.js │ │ │ │ │ ├── nl.js │ │ │ │ │ ├── no.js │ │ │ │ │ ├── pl.js │ │ │ │ │ ├── pt-br.js │ │ │ │ │ ├── pt.js │ │ │ │ │ ├── ru.js │ │ │ │ │ ├── si.js │ │ │ │ │ ├── sk.js │ │ │ │ │ ├── sl.js │ │ │ │ │ ├── sq.js │ │ │ │ │ ├── sv.js │ │ │ │ │ ├── th.js │ │ │ │ │ ├── tr.js │ │ │ │ │ ├── tt.js │ │ │ │ │ ├── ug.js │ │ │ │ │ ├── uk.js │ │ │ │ │ ├── vi.js │ │ │ │ │ ├── zh-cn.js │ │ │ │ │ └── zh.js │ │ │ │ │ └── specialchar.js │ │ │ ├── table │ │ │ │ └── dialogs │ │ │ │ │ └── table.js │ │ │ ├── tabletools │ │ │ │ └── dialogs │ │ │ │ │ └── tableCell.js │ │ │ └── wsc │ │ │ │ ├── LICENSE.md │ │ │ │ ├── README.md │ │ │ │ └── dialogs │ │ │ │ ├── ciframe.html │ │ │ │ ├── tmp.html │ │ │ │ ├── tmpFrameset.html │ │ │ │ ├── wsc.css │ │ │ │ ├── wsc.js │ │ │ │ └── wsc_ie.js │ │ ├── skins │ │ │ └── moono │ │ │ │ ├── dialog.css │ │ │ │ ├── dialog_ie.css │ │ │ │ ├── dialog_ie7.css │ │ │ │ ├── dialog_ie8.css │ │ │ │ ├── dialog_iequirks.css │ │ │ │ ├── dialog_opera.css │ │ │ │ ├── editor.css │ │ │ │ ├── editor_gecko.css │ │ │ │ ├── editor_ie.css │ │ │ │ ├── editor_ie7.css │ │ │ │ ├── editor_ie8.css │ │ │ │ ├── editor_iequirks.css │ │ │ │ ├── icons.png │ │ │ │ ├── icons_hidpi.png │ │ │ │ ├── images │ │ │ │ ├── arrow.png │ │ │ │ ├── close.png │ │ │ │ ├── hidpi │ │ │ │ │ ├── close.png │ │ │ │ │ ├── lock-open.png │ │ │ │ │ ├── lock.png │ │ │ │ │ └── refresh.png │ │ │ │ ├── lock-open.png │ │ │ │ ├── lock.png │ │ │ │ └── refresh.png │ │ │ │ └── readme.md │ │ └── styles.js │ ├── cmeditor │ │ ├── addon │ │ │ ├── comment │ │ │ │ ├── comment.js │ │ │ │ └── continuecomment.js │ │ │ ├── dialog │ │ │ │ ├── dialog.css │ │ │ │ └── dialog.js │ │ │ ├── display │ │ │ │ ├── fullscreen.css │ │ │ │ ├── fullscreen.js │ │ │ │ ├── placeholder.js │ │ │ │ └── rulers.js │ │ │ ├── edit │ │ │ │ ├── closebrackets.js │ │ │ │ ├── closetag.js │ │ │ │ ├── continuelist.js │ │ │ │ ├── matchbrackets.js │ │ │ │ ├── matchtags.js │ │ │ │ └── trailingspace.js │ │ │ ├── fold │ │ │ │ ├── brace-fold.js │ │ │ │ ├── comment-fold.js │ │ │ │ ├── foldcode.js │ │ │ │ ├── foldgutter.css │ │ │ │ ├── foldgutter.js │ │ │ │ ├── indent-fold.js │ │ │ │ ├── markdown-fold.js │ │ │ │ └── xml-fold.js │ │ │ ├── hint │ │ │ │ ├── anyword-hint.js │ │ │ │ ├── css-hint.js │ │ │ │ ├── html-hint.js │ │ │ │ ├── javascript-hint.js │ │ │ │ ├── python-hint.js │ │ │ │ ├── show-hint.css │ │ │ │ ├── show-hint.js │ │ │ │ ├── sql-hint.js │ │ │ │ └── xml-hint.js │ │ │ ├── lint │ │ │ │ ├── coffeescript-lint.js │ │ │ │ ├── css-lint.js │ │ │ │ ├── javascript-lint.js │ │ │ │ ├── json-lint.js │ │ │ │ ├── lint.css │ │ │ │ ├── lint.js │ │ │ │ └── yaml-lint.js │ │ │ ├── merge │ │ │ │ ├── merge.css │ │ │ │ └── merge.js │ │ │ ├── mode │ │ │ │ ├── loadmode.js │ │ │ │ ├── multiplex.js │ │ │ │ ├── multiplex_test.js │ │ │ │ ├── overlay.js │ │ │ │ └── simple.js │ │ │ ├── runmode │ │ │ │ ├── colorize.js │ │ │ │ ├── runmode-standalone.js │ │ │ │ ├── runmode.js │ │ │ │ └── runmode.node.js │ │ │ ├── scroll │ │ │ │ └── scrollpastend.js │ │ │ ├── search │ │ │ │ ├── match-highlighter.js │ │ │ │ ├── search.js │ │ │ │ └── searchcursor.js │ │ │ ├── selection │ │ │ │ ├── active-line.js │ │ │ │ └── mark-selection.js │ │ │ ├── tern │ │ │ │ ├── tern.css │ │ │ │ ├── tern.js │ │ │ │ └── worker.js │ │ │ └── wrap │ │ │ │ └── hardwrap.js │ │ ├── keymap │ │ │ └── vim.js │ │ ├── lib │ │ │ ├── codemirror.css │ │ │ └── codemirror.js │ │ ├── markitup.js │ │ └── mode │ │ │ ├── gfm │ │ │ ├── gfm.js │ │ │ ├── index.html │ │ │ └── test.js │ │ │ ├── markdown │ │ │ ├── index.html │ │ │ ├── markdown.js │ │ │ └── test.js │ │ │ └── xml │ │ │ ├── index.html │ │ │ ├── test.js │ │ │ └── xml.js │ ├── datetimepicker │ │ ├── bootstrap-datetimepicker.css │ │ └── bootstrap-datetimepicker.js │ ├── marked │ │ └── marked.min.js │ ├── markitup │ │ ├── jquery.markitup.js │ │ ├── loading.gif │ │ ├── sets │ │ │ └── markdown │ │ │ │ ├── ajaxfileupload.js │ │ │ │ ├── images │ │ │ │ ├── .directory │ │ │ │ ├── bold.png │ │ │ │ ├── cancel.png │ │ │ │ ├── code.png │ │ │ │ ├── h1.png │ │ │ │ ├── h2.png │ │ │ │ ├── h3.png │ │ │ │ ├── h4.png │ │ │ │ ├── h5.png │ │ │ │ ├── h6.png │ │ │ │ ├── italic.png │ │ │ │ ├── link.png │ │ │ │ ├── list-bullet.png │ │ │ │ ├── list-numeric.png │ │ │ │ ├── more.png │ │ │ │ ├── picture.png │ │ │ │ ├── picture_upload.png │ │ │ │ ├── preview.png │ │ │ │ └── quotes.png │ │ │ │ ├── set.js │ │ │ │ └── style.css │ │ ├── skins │ │ │ └── markdown │ │ │ │ ├── images │ │ │ │ ├── bg-container.png │ │ │ │ ├── bg-editor-bbcode.png │ │ │ │ ├── bg-editor-dotclear.png │ │ │ │ ├── bg-editor-html.png │ │ │ │ ├── bg-editor-json.png │ │ │ │ ├── bg-editor-markdown.png │ │ │ │ ├── bg-editor-textile.png │ │ │ │ ├── bg-editor-wiki.png │ │ │ │ ├── bg-editor-xml.png │ │ │ │ ├── bg-editor.png │ │ │ │ ├── handle.png │ │ │ │ ├── menu.png │ │ │ │ └── submenu.png │ │ │ │ └── style.css │ │ └── templates │ │ │ ├── preview.css │ │ │ └── preview.html │ ├── select2 │ │ ├── LICENSE │ │ ├── select2-spinner.gif │ │ ├── select2.css │ │ ├── select2.min.js │ │ ├── select2.png │ │ └── select2x2.png │ ├── uikit │ │ ├── css │ │ │ ├── components │ │ │ │ ├── htmleditor.css │ │ │ │ ├── htmleditor.min.css │ │ │ │ ├── upload.css │ │ │ │ └── upload.min.css │ │ │ ├── uikit.almost-flat.css │ │ │ ├── uikit.almost-flat.min.css │ │ │ ├── uikit.css │ │ │ └── uikit.min.css │ │ ├── fonts │ │ │ ├── FontAwesome.otf │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.ttf │ │ │ └── fontawesome-webfont.woff │ │ └── js │ │ │ ├── components │ │ │ ├── htmleditor.js │ │ │ ├── htmleditor.min.js │ │ │ ├── upload.js │ │ │ └── upload.min.js │ │ │ ├── core │ │ │ ├── alert.js │ │ │ ├── alert.min.js │ │ │ ├── button.js │ │ │ ├── button.min.js │ │ │ ├── core.js │ │ │ ├── core.min.js │ │ │ ├── dropdown.js │ │ │ ├── dropdown.min.js │ │ │ ├── grid.js │ │ │ ├── grid.min.js │ │ │ ├── modal.js │ │ │ ├── modal.min.js │ │ │ ├── nav.js │ │ │ ├── nav.min.js │ │ │ ├── offcanvas.js │ │ │ ├── offcanvas.min.js │ │ │ ├── scrollspy.js │ │ │ ├── scrollspy.min.js │ │ │ ├── smooth-scroll.js │ │ │ ├── smooth-scroll.min.js │ │ │ ├── switcher.js │ │ │ ├── switcher.min.js │ │ │ ├── tab.js │ │ │ ├── tab.min.js │ │ │ ├── toggle.js │ │ │ ├── toggle.min.js │ │ │ ├── tooltip.js │ │ │ ├── tooltip.min.js │ │ │ ├── touch.js │ │ │ ├── touch.min.js │ │ │ ├── utility.js │ │ │ └── utility.min.js │ │ │ ├── uikit.js │ │ │ └── uikit.min.js │ └── vendor │ │ └── jquery-1.8.3.min.js ├── favicon.ico └── robots.txt ├── templates ├── admin │ ├── index.html │ ├── model │ │ ├── a_create.html │ │ ├── a_edit.html │ │ └── editor.html │ └── my_master.html ├── sitemap.xml └── sitemap.xsl ├── themes └── imtx │ ├── info.json │ ├── static │ ├── css │ │ ├── highlight-default.css │ │ ├── login.css │ │ └── style.css │ ├── favicon.png │ ├── fonts │ │ ├── Droid_Sans.woff │ │ └── Nobile.woff │ ├── images │ │ ├── arrow.gif │ │ ├── code.png │ │ ├── databg.gif │ │ ├── digwtx-qrcode.png │ │ ├── h2_arrow.gif │ │ ├── headerbg.gif │ │ ├── li-meta.gif │ │ ├── licurrent.gif │ │ ├── loading.gif │ │ ├── logo.png │ │ ├── menubg.gif │ │ ├── nav-bg.gif │ │ ├── pattern.gif │ │ ├── rss-logo.png │ │ ├── search.gif │ │ ├── smallbg.png │ │ ├── top.png │ │ └── twitter-logo.png │ ├── js │ │ ├── highlight.min.js │ │ ├── jquery-1.8.3.min.js │ │ └── util.js │ └── mobile │ │ ├── css │ │ └── style.css │ │ └── favicon.png │ └── templates │ ├── archives.html │ ├── article.html │ ├── article_lists.html │ ├── category.html │ ├── errors │ ├── 403.html │ ├── 404.html │ └── 500.html │ ├── flatpage.html │ ├── index.html │ ├── layout.html │ ├── mobile │ ├── archives.html │ ├── article.html │ ├── article_lists.html │ ├── category.html │ ├── errors │ │ ├── 403.html │ │ ├── 404.html │ │ └── 500.html │ ├── flatpage.html │ ├── index.html │ ├── layout.html │ ├── search.html │ ├── tag.html │ ├── tags.html │ ├── topic.html │ └── topics.html │ ├── search.html │ ├── tag.html │ ├── tags.html │ ├── topic.html │ └── topics.html ├── translations └── zh_Hans_CN │ └── LC_MESSAGES │ ├── messages.mo │ └── messages.po └── utils ├── __init__.py ├── email.py ├── filters.py ├── helpers.py ├── metaweblog.py ├── processors.py ├── upload.py └── widgets.py /.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *.py[cod] 4 | 5 | # vim swap file 6 | *.swp 7 | 8 | # sqlite database files 9 | *.db 10 | *.sqlite 11 | 12 | # C extensions 13 | *.so 14 | 15 | # Distribution / packaging 16 | .Python 17 | env/ 18 | bin/ 19 | build/ 20 | develop-eggs/ 21 | dist/ 22 | eggs/ 23 | lib/ 24 | lib64/ 25 | parts/ 26 | sdist/ 27 | var/ 28 | *.egg-info/ 29 | .installed.cfg 30 | *.egg 31 | 32 | # Installer logs 33 | pip-log.txt 34 | pip-delete-this-directory.txt 35 | 36 | # Unit test / coverage reports 37 | htmlcov/ 38 | .tox/ 39 | .coverage 40 | .cache 41 | nosetests.xml 42 | coverage.xml 43 | 44 | # Translations 45 | # *.mo 46 | 47 | # Mr Developer 48 | .mr.developer.cfg 49 | .project 50 | .pydevproject 51 | 52 | # Rope 53 | .ropeproject 54 | 55 | # Django stuff: 56 | *.log 57 | *.pot 58 | 59 | # Sphinx documentation 60 | docs/_build/ 61 | 62 | -------------------------------------------------------------------------------- /.hgignore: -------------------------------------------------------------------------------- 1 | \.pyc$ 2 | \.swp$ 3 | \~$ 4 | mydeps/bae_.* 5 | \.db$ 6 | \.sqlite$ 7 | -------------------------------------------------------------------------------- /Procfile: -------------------------------------------------------------------------------- 1 | web: gunicorn wsgi:application -b $VCAP_APP_HOST:$VCAP_APP_PORT 2 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Wtxlog是基于Python Flask开发的开源的BLOG/CMS系统,以“简单实用”为目标。 2 | Wtxlog内置栏目、标签(Tags)、文章等主要模型,可以满足绝大部分的内容输出需求。 3 | 程序通用性良好,各种云主机、VPS以及应用程序引擎(BAE/JAE/SAE等)均可轻松部署。 4 | 5 | ## 主要特性 6 | 7 | - 内置模型:栏目、标签、文章、专题、友情链接等 8 | - 数据库:使用SQLAlchemy驱动,主要支持SQLITE和Mysql两种数据库 9 | - 缓存功能:主要支持Memcached和FileSystemCache两种缓存方式 10 | - 编辑器:CKEditor富文本编辑器,Markdown编辑器 11 | - 后台管理:使用Flask-Admin管理后台,功能强大,简单易用 12 | - 换肤功能:可自定义皮肤(主题),语法兼容Jinja2。内置实用的过滤器和上下 13 | 文处理器,可实现常用的查询功能。模板设计符合SEO优化理念 14 | - 代码片断:后台增加的代码片断,可在模板文件中直接调用 15 | - 其它功能:Sitemap, Feed, robots.txt, favicon.ico, etc. 16 | 17 | ## 主要依赖的第三方Flask插件 18 | 19 | - Flask-SQLAlchemy 20 | - Flask-Cache 21 | - Flask-Admin 22 | - Flask-Login 23 | - Flask-Mail 24 | 25 | ## 文档 26 | 27 | Documentation: 28 | 29 | ## 演示网站 30 | 31 | - Flask中文学习网 (SAE) 32 | - 深圳远程教育网 (BAE) 33 | -------------------------------------------------------------------------------- /app.conf: -------------------------------------------------------------------------------- 1 | handlers: 2 | - url : /favicon.ico$ 3 | script: /wtxlog/static/favicon.ico 4 | - url : /static/(.*) 5 | script : /wtxlog/static/$1 6 | - url : /admin/static/(.*) 7 | script : /wtxlog/static/admin/$1 8 | - url : /_themes/imtx/(.*) 9 | script : /wtxlog/themes/imtx/static/$1 10 | - url : /.* 11 | script : index.py 12 | 13 | - expire : .jpg modify 10 years 14 | - expire : .swf modify 10 years 15 | - expire : .png modify 10 years 16 | - expire : .gif modify 10 years 17 | - expire : .JPG modify 10 years 18 | - expire : .ico modify 10 years 19 | -------------------------------------------------------------------------------- /artwork/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/artwork/logo.png -------------------------------------------------------------------------------- /artwork/logo.svg: -------------------------------------------------------------------------------- 1 | 2 | 4 | 7 | wtxlog 8 | Created with digwtx. 9 | 11 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /config.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | name: appname 3 | version: 1 4 | handlers: 5 | - url: /favicon.ico 6 | static_path: wtxlog/static/favicon.ico 7 | - url: /static/ 8 | static_path: wtxlog/static 9 | - url: /admin/static/ 10 | static_path: wtxlog/static/admin 11 | - url: /_theme/imtx/ 12 | static_path: wtxlog/themes/imtx/static 13 | ... 14 | -------------------------------------------------------------------------------- /docs/_themes/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2010 by Armin Ronacher. 2 | 3 | Some rights reserved. 4 | 5 | Redistribution and use in source and binary forms of the theme, with or 6 | without modification, are permitted provided that the following conditions 7 | are met: 8 | 9 | * Redistributions of source code must retain the above copyright 10 | notice, this list of conditions and the following disclaimer. 11 | 12 | * Redistributions in binary form must reproduce the above 13 | copyright notice, this list of conditions and the following 14 | disclaimer in the documentation and/or other materials provided 15 | with the distribution. 16 | 17 | * The names of the contributors may not be used to endorse or 18 | promote products derived from this software without specific 19 | prior written permission. 20 | 21 | We kindly ask you to only use these themes in an unmodified manner just 22 | for Flask and Flask-related products, not for unrelated projects. If you 23 | like the visual style and want to use it for your own projects, please 24 | consider making some larger changes to the themes (such as changing 25 | font faces, sizes, colors or margins). 26 | 27 | THIS THEME IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 28 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 29 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 30 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 31 | LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 32 | CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 33 | SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 34 | INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 35 | CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 36 | ARISING IN ANY WAY OUT OF THE USE OF THIS THEME, EVEN IF ADVISED OF THE 37 | POSSIBILITY OF SUCH DAMAGE. 38 | -------------------------------------------------------------------------------- /docs/_themes/README: -------------------------------------------------------------------------------- 1 | Flask Sphinx Styles 2 | =================== 3 | 4 | This repository contains sphinx styles for Flask and Flask related 5 | projects. To use this style in your Sphinx documentation, follow 6 | this guide: 7 | 8 | 1. put this folder as _themes into your docs folder. Alternatively 9 | you can also use git submodules to check out the contents there. 10 | 2. add this to your conf.py: 11 | 12 | sys.path.append(os.path.abspath('_themes')) 13 | html_theme_path = ['_themes'] 14 | html_theme = 'flask' 15 | 16 | The following themes exist: 17 | 18 | - 'flask' - the standard flask documentation theme for large 19 | projects 20 | - 'flask_small' - small one-page theme. Intended to be used by 21 | very small addon libraries for flask. 22 | 23 | The following options exist for the flask_small theme: 24 | 25 | [options] 26 | index_logo = '' filename of a picture in _static 27 | to be used as replacement for the 28 | h1 in the index.rst file. 29 | index_logo_height = 120px height of the index logo 30 | github_fork = '' repository name on github for the 31 | "fork me" badge 32 | -------------------------------------------------------------------------------- /docs/_themes/flask/layout.html: -------------------------------------------------------------------------------- 1 | {%- extends "basic/layout.html" %} 2 | {%- block extrahead %} 3 | {{ super() }} 4 | {% if theme_touch_icon %} 5 | 6 | {% endif %} 7 | 8 | {% endblock %} 9 | {%- block relbar2 %}{% endblock %} 10 | {% block header %} 11 | {{ super() }} 12 | {% if pagename == 'index' %} 13 |
14 | {% endif %} 15 | {% endblock %} 16 | {%- block footer %} 17 | 21 | {% if pagename == 'index' %} 22 |
23 | {% endif %} 24 | {%- endblock %} 25 | -------------------------------------------------------------------------------- /docs/_themes/flask/relations.html: -------------------------------------------------------------------------------- 1 |

Related Topics

2 | 20 | -------------------------------------------------------------------------------- /docs/_themes/flask/theme.conf: -------------------------------------------------------------------------------- 1 | [theme] 2 | inherit = basic 3 | stylesheet = flasky.css 4 | pygments_style = flask_theme_support.FlaskyStyle 5 | 6 | [options] 7 | index_logo = '' 8 | index_logo_height = 120px 9 | touch_icon = 10 | github_fork = 'wtx358/wtxlog' 11 | -------------------------------------------------------------------------------- /docs/_themes/flask_small/layout.html: -------------------------------------------------------------------------------- 1 | {% extends "basic/layout.html" %} 2 | {% block header %} 3 | {{ super() }} 4 | {% if pagename == 'index' %} 5 |
6 | {% endif %} 7 | {% endblock %} 8 | {% block footer %} 9 | {% if pagename == 'index' %} 10 |
11 | {% endif %} 12 | {% endblock %} 13 | {# do not display relbars #} 14 | {% block relbar1 %}{% endblock %} 15 | {% block relbar2 %} 16 | {% if theme_github_fork %} 17 | Fork me on GitHub 19 | {% endif %} 20 | {% endblock %} 21 | {% block sidebar1 %}{% endblock %} 22 | {% block sidebar2 %}{% endblock %} 23 | -------------------------------------------------------------------------------- /docs/_themes/flask_small/theme.conf: -------------------------------------------------------------------------------- 1 | [theme] 2 | inherit = basic 3 | stylesheet = flasky.css 4 | nosidebar = true 5 | pygments_style = flask_theme_support.FlaskyStyle 6 | 7 | [options] 8 | index_logo = '' 9 | index_logo_height = 120px 10 | github_fork = '' 11 | -------------------------------------------------------------------------------- /docs/index.rst: -------------------------------------------------------------------------------- 1 | .. wtxlog documentation master file, created by 2 | sphinx-quickstart on Tue Jul 22 22:43:55 2014. 3 | You can adapt this file completely to your liking, but it should at least 4 | contain the root `toctree` directive. 5 | 6 | wtxlog (Flask BLOG/CMS) 7 | ======================= 8 | 9 | Wtxlog 是基于 Python Flask 框架开发的开源的 BLOG/CMS 系统, 以 **简单实用** 为目标. 10 | Wtxlog 内置栏目、标签(Tags)、文章等主要模型, 可以满足绝大部分的内容输出需求. 11 | 程序通用性良好, 各种云主机、VPS以及应用程序引擎(BAE/JAE/SAE等)均可轻松部署. 12 | 13 | 主要特性 14 | -------- 15 | 16 | * **内置模型:** 栏目、标签、文章、专题、友情链接等 17 | * **数据库:** 使用 SQLAlchemy 驱动, 主要支持 SQLite 和 Mysql 两种数据库 18 | * **缓存功能:** 主要支持 Memcached 和 FileSystemCache 两种缓存方式 19 | * **编辑器:** CKEditor 富文本编辑器, Markdown 编辑器, 内置图片上传功能 20 | * **后台管理:** 使用 Flask-Admin 管理后台, 功能强大, 简单易用 21 | * **换肤功能:** 可自定义皮肤(主题), 语法兼容 Jinja2. 22 | 内置实用的过滤器和上下文处理器, 可实现常用的查询功能. 23 | 模板设计符合 SEO 优化理念 24 | * **静态标签:** 后台增加的HTML代码片断(静态标签), 可在模板文件中直接调用 25 | * 支持通过 MetaWeblog 发布文章 26 | * 新增文章发布后自动 Ping 通知百度 27 | * 其它功能: Sitemap, Feed, robots.txt, favicon.ico, etc. 28 | 29 | .. note:: 30 | 源码: `wtxlog @ GitHub `_ 31 | 32 | 主要依赖的 Flask 扩展插件 33 | ------------------------- 34 | 35 | * Flask-SQLAlchemy 数据库模型 36 | * Flask-Cache 缓存 37 | * Flask-Admin 后台管理 38 | * Flask-Login 用户登录 39 | * Flask-Mail 邮件发送 40 | 41 | 42 | **Contents:** 43 | 44 | .. toctree:: 45 | :numbered: 46 | :maxdepth: 2 47 | 48 | installation.rst 49 | models.rst 50 | templating.rst 51 | 52 | -------------------------------------------------------------------------------- /index.py: -------------------------------------------------------------------------------- 1 | # -*- coding:utf-8 -*- 2 | 3 | from manage import app 4 | 5 | from bae.core.wsgi import WSGIApplication 6 | application = WSGIApplication(app, stderr='log') 7 | -------------------------------------------------------------------------------- /index.wsgi: -------------------------------------------------------------------------------- 1 | import sae 2 | 3 | from manage import app 4 | 5 | application = sae.create_wsgi_app(app) 6 | -------------------------------------------------------------------------------- /init_db.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """ 4 | Just for development time 5 | """ 6 | 7 | from manage import db 8 | from wtxlog.models import User, Role, Category 9 | 10 | if __name__ == '__main__': 11 | # init database 12 | db.create_all() 13 | 14 | # create user roles 15 | Role.insert_roles() 16 | 17 | # add administrator 18 | user = User() 19 | user.username = 'admin' 20 | user.password = 'admin' 21 | user.email = 'admin@example.com' 22 | user.role = Role.query.filter_by(permissions=0xff).first() 23 | user.confirmed = True 24 | 25 | # add default category 26 | category = Category() 27 | category.slug = 'default' 28 | category.name = 'Default' 29 | 30 | # commit 31 | db.session.add(user) 32 | db.session.add(category) 33 | db.session.commit() 34 | 35 | print('==================================') 36 | print('Init Done.') 37 | print('==================================') 38 | -------------------------------------------------------------------------------- /migrations/README: -------------------------------------------------------------------------------- 1 | Generic single-database configuration. -------------------------------------------------------------------------------- /migrations/alembic.ini: -------------------------------------------------------------------------------- 1 | # A generic, single database configuration. 2 | 3 | [alembic] 4 | # template used to generate migration files 5 | # file_template = %%(rev)s_%%(slug)s 6 | 7 | # set to 'true' to run the environment during 8 | # the 'revision' command, regardless of autogenerate 9 | # revision_environment = false 10 | 11 | 12 | # Logging configuration 13 | [loggers] 14 | keys = root,sqlalchemy,alembic 15 | 16 | [handlers] 17 | keys = console 18 | 19 | [formatters] 20 | keys = generic 21 | 22 | [logger_root] 23 | level = WARN 24 | handlers = console 25 | qualname = 26 | 27 | [logger_sqlalchemy] 28 | level = WARN 29 | handlers = 30 | qualname = sqlalchemy.engine 31 | 32 | [logger_alembic] 33 | level = INFO 34 | handlers = 35 | qualname = alembic 36 | 37 | [handler_console] 38 | class = StreamHandler 39 | args = (sys.stderr,) 40 | level = NOTSET 41 | formatter = generic 42 | 43 | [formatter_generic] 44 | format = %(levelname)-5.5s [%(name)s] %(message)s 45 | datefmt = %H:%M:%S 46 | -------------------------------------------------------------------------------- /migrations/script.py.mako: -------------------------------------------------------------------------------- 1 | """${message} 2 | 3 | Revision ID: ${up_revision} 4 | Revises: ${down_revision} 5 | Create Date: ${create_date} 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = ${repr(up_revision)} 11 | down_revision = ${repr(down_revision)} 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | ${imports if imports else ""} 16 | 17 | def upgrade(): 18 | ${upgrades if upgrades else "pass"} 19 | 20 | 21 | def downgrade(): 22 | ${downgrades if downgrades else "pass"} 23 | -------------------------------------------------------------------------------- /migrations/versions/13039747aa3_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 13039747aa3 4 | Revises: 573c11d104ad 5 | Create Date: 2014-12-05 11:02:12.375633 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '13039747aa3' 11 | down_revision = '573c11d104ad' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.create_table('settings', 20 | sa.Column('id', sa.Integer(), nullable=False), 21 | sa.Column('name', sa.String(length=128), nullable=False), 22 | sa.Column('rawvalue', sa.String(length=4096), nullable=False), 23 | sa.Column('formatter', sa.String(length=16), nullable=False), 24 | sa.Column('builtin', sa.Boolean(), nullable=True), 25 | sa.Column('description', sa.String(length=255), nullable=True), 26 | sa.PrimaryKeyConstraint('id'), 27 | sa.UniqueConstraint('name') 28 | ) 29 | ### end Alembic commands ### 30 | 31 | 32 | def downgrade(): 33 | ### commands auto generated by Alembic - please adjust! ### 34 | op.drop_table('settings') 35 | ### end Alembic commands ### 36 | -------------------------------------------------------------------------------- /migrations/versions/573c11d104ad_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 573c11d104ad 4 | Revises: 1039e4baf2c8 5 | Create Date: 2014-08-21 13:55:26.875589 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '573c11d104ad' 11 | down_revision = '1039e4baf2c8' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.add_column('friendlinks', sa.Column('order', sa.Integer(), nullable=True)) 20 | ### end Alembic commands ### 21 | 22 | 23 | def downgrade(): 24 | ### commands auto generated by Alembic - please adjust! ### 25 | op.drop_column('friendlinks', 'order') 26 | ### end Alembic commands ### 27 | -------------------------------------------------------------------------------- /mydeps/flask_restless/__init__.py: -------------------------------------------------------------------------------- 1 | """ 2 | flask.ext.restless 3 | ~~~~~~~~~~~~~~~~~~ 4 | 5 | Flask-Restless is a `Flask `_ extension which 6 | facilitates the creation of ReSTful JSON APIs. It is compatible with models 7 | which have been described using `SQLAlchemy `_. 8 | 9 | :copyright:2011 by Lincoln de Sousa 10 | :copyright:2012 Jeffrey Finkelstein 11 | :license: GNU AGPLv3+ or BSD 12 | 13 | """ 14 | 15 | #: The current version of this extension. 16 | #: 17 | #: This should be the same as the version specified in the :file:`setup.py` 18 | #: file. 19 | __version__ = '0.13.1' 20 | 21 | # make the following names available as part of the public API 22 | 23 | -------------------------------------------------------------------------------- /mydeps/mdx_joinline.py: -------------------------------------------------------------------------------- 1 | # -*- encoding: utf-8 -*- 2 | """ 3 | Join Line Extension 4 | =================== 5 | 6 | 合并段落(P)标签内的内容 7 | 8 | 主要解决VIM排版后中文内容不连续的问题 9 | 10 | Usage: 11 | 12 | >>> import markdown 13 | >>> print markdown.markdown('line 1\\nline 2', extensions=['joinline']) 14 |

line 1 line 2

15 | 16 | Note: 这个插件和nl2br冲突。 17 | 18 | Dependencies: 19 | * [Python 2.4+](http://python.org) 20 | * [Markdown 2.1+](http://packages.python.org/Markdown/) 21 | 22 | """ 23 | 24 | import re 25 | from markdown.extensions import Extension 26 | from markdown.inlinepatterns import SimpleTextPattern 27 | 28 | CR_RE = r'(\n\s*)' 29 | 30 | 31 | class MyPattern(SimpleTextPattern): 32 | 33 | def handleMatch(self, m): 34 | text = m.group(2) 35 | # 标点符号之后、单词数字之间增加一个空格 36 | if re.search(r'[.,;:?!]$', m.group(1)) or \ 37 | re.search(r'(\w+|[.,;:?!])$', m.group(1)) and \ 38 | re.match(r'\w+', m.group(3)): 39 | return ' ' 40 | return '' 41 | 42 | 43 | class JoinLineExtension(Extension): 44 | 45 | def extendMarkdown(self, md, md_globals): 46 | cr_tag = MyPattern(CR_RE) 47 | md.inlinePatterns.add('joinline', cr_tag, '_end') 48 | 49 | 50 | def makeExtension(configs=None): 51 | return JoinLineExtension(configs) 52 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | -r requirements/jae.txt 2 | 3 | -------------------------------------------------------------------------------- /requirements/bae3.txt: -------------------------------------------------------------------------------- 1 | -r common.txt 2 | MySQL-python 3 | bae_utils 4 | bae_memcache 5 | bae_image 6 | bae_log 7 | pybcs 8 | 9 | -------------------------------------------------------------------------------- /requirements/common.txt: -------------------------------------------------------------------------------- 1 | Flask==0.10.1 2 | Flask-Admin==1.0.8 3 | Flask-BabelEx==0.9.1 4 | Flask-Cache==0.13.1 5 | Flask-Login==0.2.10 6 | Flask-Mail==0.9.0 7 | Flask-Migrate==1.2.0 8 | Flask-Mobility==0.1.1 9 | Flask-SQLAlchemy==1.0 10 | Flask-Script==2.0.3 11 | Flask-WTF==0.10.2 12 | Markdown==2.4 13 | WebHelpers==1.3 14 | blinker==1.3 15 | python-dateutil==2.2 16 | qiniu==6.1.4 17 | -------------------------------------------------------------------------------- /requirements/dev.txt: -------------------------------------------------------------------------------- 1 | -r common.txt 2 | coverage==3.7.1 3 | -------------------------------------------------------------------------------- /requirements/jae.txt: -------------------------------------------------------------------------------- 1 | -r common.txt 2 | MySQL-python 3 | gunicorn==18.0 4 | 5 | -------------------------------------------------------------------------------- /runserver.bat: -------------------------------------------------------------------------------- 1 | python manage.py runserver -r -d --threaded 2 | -------------------------------------------------------------------------------- /runserver.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | python manage.py runserver -r -d --threaded 3 | -------------------------------------------------------------------------------- /tests/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/tests/__init__.py -------------------------------------------------------------------------------- /tests/test_basics.py: -------------------------------------------------------------------------------- 1 | import unittest 2 | from flask import current_app 3 | from wtxlog import create_app, db 4 | 5 | 6 | class BasicsTestCase(unittest.TestCase): 7 | def setUp(self): 8 | self.app = create_app('testing') 9 | self.app_context = self.app.app_context() 10 | self.app_context.push() 11 | db.create_all() 12 | 13 | def tearDown(self): 14 | db.session.remove() 15 | db.drop_all() 16 | self.app_context.pop() 17 | 18 | def test_app_exists(self): 19 | self.assertFalse(current_app is None) 20 | 21 | def test_app_is_testing(self): 22 | self.assertTrue(current_app.config['TESTING']) 23 | -------------------------------------------------------------------------------- /tests/test_search.py: -------------------------------------------------------------------------------- 1 | # -*- encoding: utf-8 -*- 2 | 3 | import datetime 4 | import unittest 5 | from flask import url_for 6 | from wtxlog import create_app, db 7 | from wtxlog.models import Article, Category, Tag, Role 8 | 9 | 10 | class SearchTestCase(unittest.TestCase): 11 | def setUp(self): 12 | self.app = create_app('testing') 13 | self.app_context = self.app.app_context() 14 | self.app_context.push() 15 | db.create_all() 16 | Role.insert_roles() 17 | self.client = self.app.test_client(use_cookies=True) 18 | 19 | def tearDown(self): 20 | db.session.remove() 21 | db.drop_all() 22 | self.app_context.pop() 23 | 24 | def test_tags_search(self): 25 | tag1 = Tag(name=u'中国') 26 | tag2 = Tag(name=u'China') 27 | db.session.add(tag1) 28 | db.session.add(tag2) 29 | db.session.commit() 30 | tags1 = Tag.query.search(u'中国') 31 | tags2 = Tag.query.search(u'China') 32 | self.assertTrue(tag1 in tags1) 33 | self.assertTrue(tag2 in tags2) 34 | 35 | def test_articles_search(self): 36 | category = Category(name=u'默认', slug='default1') 37 | db.session.add(category) 38 | db.session.commit() 39 | article = Article(title=u'我是中国人', category_id=category.id, 40 | body='hello flask', created=datetime.datetime.now(), 41 | last_modified=datetime.datetime.now()) 42 | db.session.add(article) 43 | db.session.commit() 44 | articles = Article.query.search(u'中国') 45 | self.assertTrue(article in articles) 46 | -------------------------------------------------------------------------------- /wsgi.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | from manage import app as application 4 | -------------------------------------------------------------------------------- /wtxlog/account/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | from flask import Blueprint 4 | 5 | account = Blueprint('account', __name__, template_folder='templates', 6 | static_folder='static') 7 | 8 | from . import views 9 | -------------------------------------------------------------------------------- /wtxlog/account/templates/base.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | {% block title %}{% endblock %} - {{ config['SITE_NAME'] }} 6 | 7 | 8 | 9 | 10 | {# 定义导航菜单 #} 11 | {% set navigation_bar = [ 12 | (url_for('account.index'), 'index', _('Index'), 0), 13 | (url_for('admin.index'), 'admin', _('Admin'), 2), 14 | (url_for('account.change_password'), 'change-password', _('Change Password'), 1), 15 | (url_for('account.change_email_request'), 'change-email', _('Change Email'), 1), 16 | (url_for('account.logout'), 'logout', _('Logout'), 1), 17 | ] -%} 18 | {% set active_page = active_page|default('index') -%} 19 | {% set permission = 0 %} 20 | {% if current_user.is_authenticated() %}{% set permission = 1 %}{% endif %} 21 | {% if current_user.is_administrator() %}{% set permission = 2 %}{% endif %} 22 | 23 |
24 | 34 | 35 | {% for message in get_flashed_messages() %} 36 |
{{ message }}
37 | {% endfor %} 38 | 39 | {% block body %}{% endblock %} 40 |
41 | 42 | 43 | -------------------------------------------------------------------------------- /wtxlog/account/templates/change_email.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% set active_page = 'change-email' %} 4 | 5 | {% block title %}{{ _('Change Email') }}{% endblock %} 6 | 7 | {% block body %} 8 |
9 | {{ _('Change Email') }} 10 |
11 | {{ form.hidden_tag() if form.hidden_tag }} 12 | {% for field in form if field.type not in ('CSRFTokenField', 'SubmitField') %} 13 |
14 | {{ field.label(class='control-label') }} 15 |
16 |
{{ field }}
17 | {% if field.errors %} 18 |
    19 | {% for error in field.errors %} 20 |
  • {{ error }}
  • 21 | {% endfor %} 22 |
23 | {% endif %} 24 |
25 |
26 | {% endfor %} 27 |
28 |
29 | 30 |
31 |
32 |
33 |
34 | {% endblock %} 35 | -------------------------------------------------------------------------------- /wtxlog/account/templates/change_password.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% set active_page = 'change-password' %} 4 | 5 | {% block title %}{{ _('Change Password') }}{% endblock %} 6 | 7 | {% block body %} 8 |
9 | {{ _('Change Password') }} 10 |
11 | {{ form.hidden_tag() if form.hidden_tag }} 12 | {% for field in form if field.type not in ('CSRFTokenField', 'SubmitField') %} 13 |
14 | {{ field.label(class='control-label') }} 15 |
16 |
{{ field }}
17 | {% if field.errors %} 18 |
    19 | {% for error in field.errors %} 20 |
  • {{ error }}
  • 21 | {% endfor %} 22 |
23 | {% endif %} 24 |
25 |
26 | {% endfor %} 27 |
28 |
29 | 30 |
31 |
32 |
33 |
34 | {% endblock %} 35 | -------------------------------------------------------------------------------- /wtxlog/account/templates/email/change_email.html: -------------------------------------------------------------------------------- 1 |

Dear {{ user.username }},

2 |

To confirm your new email address click here.

3 |

Alternatively, you can paste the following link in your browser's address bar:

4 |

{{ url_for('account.change_email', token=token, _external=True) }}

5 |

Sincerely,

6 |

The {{ config['SITE_NAME'] }} Team

7 |

Note: replies to this email address are not monitored.

8 | -------------------------------------------------------------------------------- /wtxlog/account/templates/email/change_email.txt: -------------------------------------------------------------------------------- 1 | Dear {{ user.username }}, 2 | 3 | To confirm your new email address click on the following link: 4 | 5 | {{ url_for('account.change_email', token=token, _external=True) }} 6 | 7 | Sincerely, 8 | 9 | The {{ config['SITE_NAME'] }} Team 10 | 11 | Note: replies to this email address are not monitored. 12 | -------------------------------------------------------------------------------- /wtxlog/account/templates/email/confirm.html: -------------------------------------------------------------------------------- 1 |

Dear {{ user.username }},

2 |

Welcome to {{ config['SITE_NAME'] }}!

3 |

To confirm your account please click here.

4 |

Alternatively, you can paste the following link in your browser's address bar:

5 |

{{ url_for('account.confirm', token=token, _external=True) }}

6 |

Sincerely,

7 |

The {{ config['SITE_NAME'] }} Team

8 |

Note: replies to this email address are not monitored.

9 | -------------------------------------------------------------------------------- /wtxlog/account/templates/email/confirm.txt: -------------------------------------------------------------------------------- 1 | Dear {{ user.username }}, 2 | 3 | Welcome to {{ config['SITE_NAME'] }}! 4 | 5 | To confirm your account please click on the following link: 6 | 7 | {{ url_for('account.confirm', token=token, _external=True) }} 8 | 9 | Sincerely, 10 | 11 | The {{ config['SITE_NAME'] }} Team 12 | 13 | Note: replies to this email address are not monitored. 14 | -------------------------------------------------------------------------------- /wtxlog/account/templates/email/reset_password.html: -------------------------------------------------------------------------------- 1 |

Dear {{ user.username }},

2 |

To reset your password click here.

3 |

Alternatively, you can paste the following link in your browser's address bar:

4 |

{{ url_for('account.password_reset', token=token, _external=True) }}

5 |

If you have not requested a password reset simply ignore this message.

6 |

Sincerely,

7 |

The {{ config['SITE_NAME'] }} Team

8 |

Note: replies to this email address are not monitored.

9 | -------------------------------------------------------------------------------- /wtxlog/account/templates/email/reset_password.txt: -------------------------------------------------------------------------------- 1 | Dear {{ user.username }}, 2 | 3 | To reset your password click on the following link: 4 | 5 | {{ url_for('account.password_reset', token=token, _external=True) }} 6 | 7 | If you have not requested a password reset simply ignore this message. 8 | 9 | Sincerely, 10 | 11 | The {{ config['SITE_NAME'] }} Team 12 | 13 | Note: replies to this email address are not monitored. 14 | -------------------------------------------------------------------------------- /wtxlog/account/templates/index.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block title %}{{ _('Index') }}{% endblock %} 4 | 5 | {% block body %} 6 | 7 |
8 |

9 |

10 | Hello, {{ current_user.username }}! 11 |

12 | {% if not current_user.confirmed %} 13 |

You have not confirmed your account yet.

14 |

15 | Before you can access this site you need to confirm your account. 16 | Check your inbox, you should have received an email with a confirmation link. 17 |

18 |

19 | Need another confirmation email? 20 | Click here 21 |

22 | {% endif %} 23 |
24 | 25 | {% endblock %} 26 | -------------------------------------------------------------------------------- /wtxlog/account/templates/login.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block title %}{{ _('Login') }}{% endblock %} 4 | 5 | {% block body %} 6 |
7 | {{ _('Login') }} 8 |
9 | {{ form.hidden_tag() if form.hidden_tag }} 10 | {% for field in form if field.name in ('email', 'password') %} 11 |
12 | {{ field.label(class='control-label') }} 13 |
14 |
{{ field }}
15 | {% if field.errors %} 16 |
    17 | {% for error in field.errors %} 18 |
  • {{ error }}
  • 19 | {% endfor %} 20 |
21 | {% endif %} 22 |
23 |
24 | {% endfor %} 25 |
26 | 27 |
28 | 29 |
30 |
31 |
32 |
33 |

{{ _('Forgot your password?') }}

34 |

{{ _('Need an account? Register free.') }}

35 | {% endblock %} 36 | -------------------------------------------------------------------------------- /wtxlog/account/templates/register.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block title %}{{ _('Register') }}{% endblock %} 4 | 5 | {% block body %} 6 |
7 | {{ _('Register') }} 8 |
9 | {{ form.hidden_tag() if form.hidden_tag }} 10 | {% for field in form if field.type not in ('CSRFTokenField', 'SubmitField') %} 11 |
12 | {{ field.label(class='control-label') }} 13 |
14 |
{{ field }}
15 | {% if field.errors %} 16 |
    17 | {% for error in field.errors %} 18 |
  • {{ error }}
  • 19 | {% endfor %} 20 |
21 | {% endif %} 22 |
23 |
24 | {% endfor %} 25 |
26 |
27 | 28 |
29 |
30 |
31 |
32 | 33 |

{{ _('Already have an account, Login Please.') }}

34 | {% endblock %} 35 | -------------------------------------------------------------------------------- /wtxlog/account/templates/reset_password.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block title %}{{ _('Reset Password') }}{% endblock %} 4 | 5 | {% block body %} 6 |
7 | {{ _('Reset Password') }} 8 |
9 | {{ form.hidden_tag() if form.hidden_tag }} 10 | {% for field in form if field.type not in ('CSRFTokenField', 'SubmitField') %} 11 |
12 | {{ field.label(class='control-label') }} 13 |
14 |
{{ field }}
15 | {% if field.errors %} 16 |
    17 | {% for error in field.errors %} 18 |
  • {{ error }}
  • 19 | {% endfor %} 20 |
21 | {% endif %} 22 |
23 |
24 | {% endfor %} 25 |
26 |
27 | 28 |
29 |
30 |
31 |
32 |

{{ _('Login') }}

33 | {% endblock %} 34 | -------------------------------------------------------------------------------- /wtxlog/api/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | from flask import Blueprint 4 | 5 | api = Blueprint('api', __name__) 6 | 7 | from . import views 8 | -------------------------------------------------------------------------------- /wtxlog/api/views.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | from flask import request 4 | from ..models import db, Article 5 | from . import api 6 | 7 | 8 | @api.route('/gethits/') 9 | def gethits(): 10 | id = int(request.args.get('id', 0)) 11 | article = Article.query.get(id) 12 | if article: 13 | article.hits += 1 14 | db.session.add(article) 15 | db.session.commit() 16 | return str(article.hits) 17 | return 'err' 18 | -------------------------------------------------------------------------------- /wtxlog/babel/babel.ini: -------------------------------------------------------------------------------- 1 | # Python 2 | [python: **.py] 3 | # Jinja2 4 | [jinja2: **/templates/**.html] 5 | extensions=jinja2.ext.autoescape,jinja2.ext.with_ 6 | encoding = utf-8 7 | -------------------------------------------------------------------------------- /wtxlog/babel/tr_compile.py: -------------------------------------------------------------------------------- 1 | # -*- encoding: utf-8 -*- 2 | import os 3 | import sys 4 | if sys.platform == 'win32': 5 | pybabel = 'pybabel' 6 | else: 7 | pybabel = 'pybabel' 8 | os.system(pybabel + ' compile -d ../translations') 9 | -------------------------------------------------------------------------------- /wtxlog/babel/tr_init.py: -------------------------------------------------------------------------------- 1 | # -*- encoding: utf-8 -*- 2 | import os 3 | import sys 4 | if sys.platform == 'win32': 5 | pybabel = 'pybabel' 6 | else: 7 | pybabel = 'pybabel' 8 | if len(sys.argv) != 2: 9 | print("usage: tr_init ") 10 | sys.exit(1) 11 | os.system(pybabel + ' extract -F babel.ini -k lazy_gettext --project wtxlog -o messages.pot ..') 12 | os.system(pybabel + ' init -i messages.pot -d ../translations -l ' + sys.argv[1]) 13 | os.unlink('messages.pot') 14 | -------------------------------------------------------------------------------- /wtxlog/babel/tr_update.py: -------------------------------------------------------------------------------- 1 | # -*- encoding: utf-8 -*- 2 | import os 3 | import sys 4 | if sys.platform == 'win32': 5 | pybabel = 'pybabel' 6 | else: 7 | pybabel = 'pybabel' 8 | os.system(pybabel + ' extract -F babel.ini -k lazy_gettext --project wtxlog -o messages.pot ..') 9 | os.system(pybabel + ' update -i messages.pot -d ../translations') 10 | os.unlink('messages.pot') 11 | -------------------------------------------------------------------------------- /wtxlog/decorators.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | from threading import Thread 4 | from functools import wraps 5 | from flask import abort 6 | from flask.ext.login import current_user 7 | 8 | from models import Permission 9 | 10 | 11 | def async(f): 12 | def wrapper(*args, **kwargs): 13 | thr = Thread(target=f, args=args, kwargs=kwargs) 14 | thr.start() 15 | return wrapper 16 | 17 | 18 | def permission_required(permission): 19 | def decorator(f): 20 | @wraps(f) 21 | def decorated_function(*args, **kwargs): 22 | if not current_user.can(permission): 23 | abort(403) 24 | return f(*args, **kwargs) 25 | return decorated_function 26 | return decorator 27 | 28 | 29 | def admin_required(f): 30 | return permission_required(Permission.ADMINISTER)(f) 31 | -------------------------------------------------------------------------------- /wtxlog/main/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | from flask import Blueprint 4 | 5 | main = Blueprint('main', __name__) 6 | 7 | from ..models import Permission 8 | from . import views, errors 9 | 10 | 11 | @main.app_context_processor 12 | def inject_permissions(): 13 | return dict(Permission=Permission) 14 | -------------------------------------------------------------------------------- /wtxlog/main/errors.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | from flask import request, jsonify, redirect 4 | from flask.ext.mobility.decorators import mobile_template 5 | from ..utils.helpers import render_template 6 | from ..models import db, Redirect 7 | from . import main 8 | 9 | 10 | @main.app_errorhandler(403) 11 | @mobile_template('{mobile/}%s') 12 | def forbidden(e, template): 13 | if request.accept_mimetypes.accept_json and \ 14 | not request.accept_mimetypes.accept_html: 15 | response = jsonify({'error': 'forbidden'}) 16 | response.status_code = 403 17 | return response 18 | _template = template % 'errors/403.html' 19 | return render_template(_template), 403 20 | 21 | 22 | @main.app_errorhandler(404) 23 | @mobile_template('{mobile/}%s') 24 | def page_not_found(e, template): 25 | try: 26 | _r = Redirect.query.filter_by(old_path=request.path).first() 27 | if _r: 28 | return redirect(_r.new_path, code=301) 29 | except: 30 | pass 31 | 32 | if request.accept_mimetypes.accept_json and \ 33 | not request.accept_mimetypes.accept_html: 34 | response = jsonify({'error': 'not found'}) 35 | response.status_code = 404 36 | return response 37 | _template = template % 'errors/404.html' 38 | return render_template(_template), 404 39 | 40 | 41 | @main.app_errorhandler(500) 42 | @mobile_template('{mobile/}%s') 43 | def internal_server_error(e, template): 44 | try: 45 | db.session.rollback() 46 | except: 47 | pass 48 | if request.accept_mimetypes.accept_json and \ 49 | not request.accept_mimetypes.accept_html: 50 | response = jsonify({'error': 'internal server error'}) 51 | response.status_code = 500 52 | return response 53 | _template = template % 'errors/500.html' 54 | return render_template(_template), 500 55 | -------------------------------------------------------------------------------- /wtxlog/static/admin/admin/css/admin.css: -------------------------------------------------------------------------------- 1 | /* Global styles */ 2 | body 3 | { 4 | padding-top: 4px; 5 | } 6 | 7 | /* Form customizations */ 8 | form.icon { 9 | display: inline; 10 | } 11 | 12 | form.icon button { 13 | border: none; 14 | background: transparent; 15 | text-decoration: none; 16 | padding: 0; 17 | line-height: normal; 18 | } 19 | 20 | a.icon { 21 | text-decoration: none; 22 | color: black; 23 | } 24 | 25 | /* Model search form */ 26 | form.search-form { 27 | margin: 4px 0 0 0; 28 | } 29 | 30 | form.search-form .clear i { 31 | margin: 2px 0 0 0; 32 | } 33 | 34 | form.search-form div input { 35 | margin: 0; 36 | } 37 | 38 | /* Filters */ 39 | table.filters { 40 | border-collapse: collapse; 41 | border-spacing: 4px; 42 | } 43 | 44 | .filters input 45 | { 46 | margin-bottom: 0; 47 | } 48 | 49 | .filters a.remove-filter { 50 | margin-bottom: 0; 51 | display: block; 52 | text-align: left; 53 | } 54 | 55 | .filters .remove-filter 56 | { 57 | vertical-align: middle; 58 | } 59 | 60 | .filters .remove-filter .close-icon 61 | { 62 | font-size: 16px; 63 | } 64 | 65 | .filters .remove-filter .close-icon:hover 66 | { 67 | color: black; 68 | opacity: 0.4; 69 | } 70 | 71 | .filters .filter-op > a { 72 | height: 28px; 73 | line-height: 28px; 74 | } 75 | 76 | /* Inline forms */ 77 | .inline-field { 78 | padding-bottom: 0.5em; 79 | } 80 | 81 | .inline-field-control { 82 | float: right; 83 | } 84 | 85 | .inline-field .inline-form-field { 86 | border-left: 1px solid #eeeeee; 87 | padding-left: 8px; 88 | margin-bottom: 4px; 89 | } 90 | 91 | /* Image thumbnails */ 92 | .image-thumbnail img { 93 | max-width: 100px; 94 | max-height: 100px; 95 | } 96 | 97 | /* Forms */ 98 | .form-horizontal .control-label { 99 | width: 100px; 100 | text-align: left; 101 | margin-left: 4px; 102 | } 103 | 104 | .form-horizontal .controls { 105 | margin-left: 110px; 106 | } 107 | 108 | /* Patch Select2 */ 109 | .select2-results li { 110 | min-height: 24px !important; 111 | } 112 | 113 | .list-checkbox-column { 114 | width: 14px; 115 | } 116 | -------------------------------------------------------------------------------- /wtxlog/static/admin/admin/css/rediscli.css: -------------------------------------------------------------------------------- 1 | .console { 2 | position: relative; 3 | width: 100%; 4 | min-height: 400px; 5 | } 6 | 7 | .console-container { 8 | border-radius: 4px; 9 | position: absolute; 10 | border: 1px solid #d4d4d4; 11 | padding: 2px; 12 | overflow: scroll; 13 | top: 2px; 14 | left: 2px; 15 | right: 2px; 16 | bottom: 5em; 17 | } 18 | 19 | .console-line { 20 | position: absolute; 21 | left: 2px; 22 | right: 2px; 23 | bottom: 2px; 24 | } 25 | 26 | .console-line input { 27 | width: 100%; 28 | box-sizing: border-box; 29 | -moz-box-sizing: border-box; 30 | -webkit-box-sizing: border-box; 31 | height: 2em; 32 | } 33 | 34 | .console .cmd { 35 | background-color: #f5f5f5; 36 | padding: 2px; 37 | margin: 1px; 38 | } 39 | 40 | .console .response { 41 | background-color: #f0f0f0; 42 | padding: 2px; 43 | margin: 1px; 44 | } 45 | 46 | .console .error { 47 | color: red; 48 | } -------------------------------------------------------------------------------- /wtxlog/static/admin/admin/js/actions.js: -------------------------------------------------------------------------------- 1 | var AdminModelActions = function(actionErrorMessage, actionConfirmations) { 2 | // Actions helpers. TODO: Move to separate file 3 | this.execute = function(name) { 4 | var selected = $('input.action-checkbox:checked').size(); 5 | 6 | if (selected === 0) { 7 | alert(actionErrorMessage); 8 | return false; 9 | } 10 | 11 | var msg = actionConfirmations[name]; 12 | 13 | if (!!msg) 14 | if (!confirm(msg)) 15 | return false; 16 | 17 | // Update hidden form and submit it 18 | var form = $('#action_form'); 19 | $('#action', form).val(name); 20 | 21 | $('input.action-checkbox', form).remove(); 22 | $('input.action-checkbox:checked').each(function() { 23 | form.append($(this).clone()); 24 | }); 25 | 26 | form.submit(); 27 | 28 | return false; 29 | }; 30 | 31 | $(function() { 32 | $('.action-rowtoggle').change(function() { 33 | $('input.action-checkbox').attr('checked', this.checked); 34 | }); 35 | }); 36 | }; 37 | -------------------------------------------------------------------------------- /wtxlog/static/admin/bootstrap/img/glyphicons-halflings-white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/bootstrap/img/glyphicons-halflings-white.png -------------------------------------------------------------------------------- /wtxlog/static/admin/bootstrap/img/glyphicons-halflings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/bootstrap/img/glyphicons-halflings.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/config.js: -------------------------------------------------------------------------------- 1 | /** 2 | * @license Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | * For licensing, see LICENSE.html or http://ckeditor.com/license 4 | */ 5 | 6 | CKEDITOR.editorConfig = function( config ) { 7 | // Define changes to default configuration here. 8 | // For the complete reference: 9 | // http://docs.ckeditor.com/#!/api/CKEDITOR.config 10 | 11 | // The toolbar groups arrangement, optimized for two toolbar rows. 12 | config.toolbarGroups = [ 13 | { name: 'clipboard', groups: [ 'clipboard', 'undo' ] }, 14 | { name: 'editing', groups: [ 'find', 'selection', 'spellchecker' ] }, 15 | { name: 'links' }, 16 | { name: 'insert' }, 17 | { name: 'forms' }, 18 | { name: 'tools' }, 19 | { name: 'document', groups: [ 'mode', 'document', 'doctools' ] }, 20 | { name: 'others' }, 21 | '/', 22 | { name: 'basicstyles', groups: [ 'basicstyles', 'cleanup' ] }, 23 | { name: 'paragraph', groups: [ 'list', 'indent', 'blocks', 'align', 'bidi' ] }, 24 | { name: 'styles' }, 25 | { name: 'colors' }, 26 | { name: 'about' } 27 | ]; 28 | 29 | // Remove some buttons, provided by the standard plugins, which we don't 30 | // need to have in the Standard(s) toolbar. 31 | config.removeButtons = 'Underline,Subscript,Superscript'; 32 | 33 | // Se the most common block elements. 34 | config.format_tags = 'p;h1;h2;h3;pre'; 35 | 36 | // Make dialogs simpler. 37 | config.removeDialogTabs = 'image:advanced;link:advanced'; 38 | 39 | config.extraPlugins = 'justify,font,colordialog,colorbutton'; 40 | 41 | // file upload url 42 | config.filebrowserUploadUrl = '/ckupload/'; 43 | 44 | config.width = 700; 45 | config.height = 360; 46 | config.resize_enabled = false; 47 | }; 48 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/contents.css: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | 6 | body 7 | { 8 | /* Font */ 9 | font-family: sans-serif, Arial, Verdana, "Trebuchet MS"; 10 | font-size: 12px; 11 | 12 | /* Text color */ 13 | color: #333; 14 | 15 | /* Remove the background color to make it transparent */ 16 | background-color: #fff; 17 | 18 | margin: 20px; 19 | } 20 | 21 | .cke_editable 22 | { 23 | font-size: 13px; 24 | line-height: 1.6; 25 | } 26 | 27 | blockquote 28 | { 29 | font-style: italic; 30 | font-family: Georgia, Times, "Times New Roman", serif; 31 | padding: 2px 0; 32 | border-style: solid; 33 | border-color: #ccc; 34 | border-width: 0; 35 | } 36 | 37 | .cke_contents_ltr blockquote 38 | { 39 | padding-left: 20px; 40 | padding-right: 8px; 41 | border-left-width: 5px; 42 | } 43 | 44 | .cke_contents_rtl blockquote 45 | { 46 | padding-left: 8px; 47 | padding-right: 20px; 48 | border-right-width: 5px; 49 | } 50 | 51 | a 52 | { 53 | color: #0782C1; 54 | } 55 | 56 | ol,ul,dl 57 | { 58 | /* IE7: reset rtl list margin. (#7334) */ 59 | *margin-right: 0px; 60 | /* preserved spaces for list items with text direction other than the list. (#6249,#8049)*/ 61 | padding: 0 40px; 62 | } 63 | 64 | h1,h2,h3,h4,h5,h6 65 | { 66 | font-weight: normal; 67 | line-height: 1.2; 68 | } 69 | 70 | hr 71 | { 72 | border: 0px; 73 | border-top: 1px solid #ccc; 74 | } 75 | 76 | img.right 77 | { 78 | border: 1px solid #ccc; 79 | float: right; 80 | margin-left: 15px; 81 | padding: 5px; 82 | } 83 | 84 | img.left 85 | { 86 | border: 1px solid #ccc; 87 | float: left; 88 | margin-right: 15px; 89 | padding: 5px; 90 | } 91 | 92 | pre 93 | { 94 | white-space: pre-wrap; /* CSS 2.1 */ 95 | word-wrap: break-word; /* IE7 */ 96 | } 97 | 98 | .marker 99 | { 100 | background-color: Yellow; 101 | } 102 | 103 | span[lang] 104 | { 105 | font-style: italic; 106 | } 107 | 108 | figure 109 | { 110 | text-align: center; 111 | border: solid 1px #ccc; 112 | border-radius: 2px; 113 | background: rgba(0,0,0,0.05); 114 | padding: 10px; 115 | margin: 10px 20px; 116 | display: block; /* For IE8 */ 117 | } 118 | 119 | figure figcaption 120 | { 121 | text-align: center; 122 | display: block; /* For IE8 */ 123 | } 124 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/a11yhelp/dialogs/lang/_translationstatus.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 2 | For licensing, see LICENSE.md or http://ckeditor.com/license 3 | 4 | cs.js Found: 30 Missing: 0 5 | cy.js Found: 30 Missing: 0 6 | da.js Found: 12 Missing: 18 7 | de.js Found: 30 Missing: 0 8 | el.js Found: 25 Missing: 5 9 | eo.js Found: 30 Missing: 0 10 | fa.js Found: 30 Missing: 0 11 | fi.js Found: 30 Missing: 0 12 | fr.js Found: 30 Missing: 0 13 | gu.js Found: 12 Missing: 18 14 | he.js Found: 30 Missing: 0 15 | it.js Found: 30 Missing: 0 16 | mk.js Found: 5 Missing: 25 17 | nb.js Found: 30 Missing: 0 18 | nl.js Found: 30 Missing: 0 19 | no.js Found: 30 Missing: 0 20 | pt-br.js Found: 30 Missing: 0 21 | ro.js Found: 6 Missing: 24 22 | tr.js Found: 30 Missing: 0 23 | ug.js Found: 27 Missing: 3 24 | vi.js Found: 6 Missing: 24 25 | zh-cn.js Found: 30 Missing: 0 26 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/about/dialogs/about.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.dialog.add("about",function(a){var a=a.lang.about,b=CKEDITOR.plugins.get("about").path+"dialogs/"+(CKEDITOR.env.hidpi?"hidpi/":"")+"logo_ckeditor.png";return{title:CKEDITOR.env.ie?a.dlgTitle:a.title,minWidth:390,minHeight:230,contents:[{id:"tab1",label:"",title:"",expand:!0,padding:0,elements:[{type:"html",html:'

CKEditor '+CKEDITOR.version+" (revision "+CKEDITOR.revision+')
http://ckeditor.com

'+a.help.replace("$1",''+ 7 | a.userGuide+"")+"

"+a.moreInfo+'
http://ckeditor.com/about/license

'+a.copy.replace("$1",'CKSource - Frederico Knabben')+"

"}]}],buttons:[CKEDITOR.dialog.cancelButton]}}); -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/about/dialogs/hidpi/logo_ckeditor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/about/dialogs/hidpi/logo_ckeditor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/about/dialogs/logo_ckeditor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/about/dialogs/logo_ckeditor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/bgcolor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/bgcolor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/hidpi/bgcolor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/hidpi/bgcolor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/hidpi/textcolor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/hidpi/textcolor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/textcolor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/colorbutton/icons/textcolor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colorbutton/lang/en.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'colorbutton', 'en', { 6 | auto: 'Automatic', 7 | bgColorTitle: 'Background Color', 8 | colors: { 9 | '000': 'Black', 10 | '800000': 'Maroon', 11 | '8B4513': 'Saddle Brown', 12 | '2F4F4F': 'Dark Slate Gray', 13 | '008080': 'Teal', 14 | '000080': 'Navy', 15 | '4B0082': 'Indigo', 16 | '696969': 'Dark Gray', 17 | B22222: 'Fire Brick', 18 | A52A2A: 'Brown', 19 | DAA520: 'Golden Rod', 20 | '006400': 'Dark Green', 21 | '40E0D0': 'Turquoise', 22 | '0000CD': 'Medium Blue', 23 | '800080': 'Purple', 24 | '808080': 'Gray', 25 | F00: 'Red', 26 | FF8C00: 'Dark Orange', 27 | FFD700: 'Gold', 28 | '008000': 'Green', 29 | '0FF': 'Cyan', 30 | '00F': 'Blue', 31 | EE82EE: 'Violet', 32 | A9A9A9: 'Dim Gray', 33 | FFA07A: 'Light Salmon', 34 | FFA500: 'Orange', 35 | FFFF00: 'Yellow', 36 | '00FF00': 'Lime', 37 | AFEEEE: 'Pale Turquoise', 38 | ADD8E6: 'Light Blue', 39 | DDA0DD: 'Plum', 40 | D3D3D3: 'Light Grey', 41 | FFF0F5: 'Lavender Blush', 42 | FAEBD7: 'Antique White', 43 | FFFFE0: 'Light Yellow', 44 | F0FFF0: 'Honeydew', 45 | F0FFFF: 'Azure', 46 | F0F8FF: 'Alice Blue', 47 | E6E6FA: 'Lavender', 48 | FFF: 'White' 49 | }, 50 | more: 'More Colors...', 51 | panelTitle: 'Colors', 52 | textColorTitle: 'Text Color' 53 | } ); 54 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colorbutton/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'colorbutton', 'zh-cn', { 6 | auto: '自动', 7 | bgColorTitle: '背景颜色', 8 | colors: { 9 | '000': '黑', 10 | '800000': '褐红', 11 | '8B4513': '深褐', 12 | '2F4F4F': '墨绿', 13 | '008080': '绿松石', 14 | '000080': '海军蓝', 15 | '4B0082': '靛蓝', 16 | '696969': '暗灰', 17 | B22222: '砖红', 18 | A52A2A: '褐', 19 | DAA520: '金黄', 20 | '006400': '深绿', 21 | '40E0D0': '蓝绿', 22 | '0000CD': '中蓝', 23 | '800080': '紫', 24 | '808080': '灰', 25 | F00: '红', 26 | FF8C00: '深橙', 27 | FFD700: '金', 28 | '008000': '绿', 29 | '0FF': '青', 30 | '00F': '蓝', 31 | EE82EE: '紫罗兰', 32 | A9A9A9: '深灰', 33 | FFA07A: '亮橙', 34 | FFA500: '橙', 35 | FFFF00: '黄', 36 | '00FF00': '水绿', 37 | AFEEEE: '粉蓝', 38 | ADD8E6: '亮蓝', 39 | DDA0DD: '梅红', 40 | D3D3D3: '淡灰', 41 | FFF0F5: '淡紫红', 42 | FAEBD7: '古董白', 43 | FFFFE0: '淡黄', 44 | F0FFF0: '蜜白', 45 | F0FFFF: '天蓝', 46 | F0F8FF: '淡蓝', 47 | E6E6FA: '淡紫', 48 | FFF: '白' 49 | }, 50 | more: '其它颜色...', 51 | panelTitle: '颜色', 52 | textColorTitle: '文本颜色' 53 | } ); 54 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colorbutton/lang/zh.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'colorbutton', 'zh', { 6 | auto: '自動', 7 | bgColorTitle: '背景顏色', 8 | colors: { 9 | '000': '黑色', 10 | '800000': '栗色', 11 | '8B4513': '鞍褐色', 12 | '2F4F4F': '暗瓦灰色', 13 | '008080': '水壓色', 14 | '000080': '丈青澀', 15 | '4B0082': '靛青', 16 | '696969': '深灰色', 17 | B22222: '磚紅色', 18 | A52A2A: '褐色', 19 | DAA520: '金黃色', 20 | '006400': '深綠色', 21 | '40E0D0': '青綠色', 22 | '0000CD': '藍色', 23 | '800080': '紫色', 24 | '808080': '灰色', 25 | F00: '紅色', 26 | FF8C00: '深橘色', 27 | FFD700: '金色', 28 | '008000': '綠色', 29 | '0FF': '藍綠色', 30 | '00F': '藍色', 31 | EE82EE: '紫色', 32 | A9A9A9: '暗灰色', 33 | FFA07A: '亮鮭紅', 34 | FFA500: '橘色', 35 | FFFF00: '黃色', 36 | '00FF00': '鮮綠色', 37 | AFEEEE: '綠松色', 38 | ADD8E6: '淺藍色', 39 | DDA0DD: '枚紅色', 40 | D3D3D3: '淺灰色', 41 | FFF0F5: '淺紫色', 42 | FAEBD7: '骨董白', 43 | FFFFE0: '淺黃色', 44 | F0FFF0: '蜜瓜綠', 45 | F0FFFF: '天藍色', 46 | F0F8FF: '愛麗斯蘭', 47 | E6E6FA: '淺紫色', 48 | FFF: '白色' 49 | }, 50 | more: '更多顏色', 51 | panelTitle: '顏色', 52 | textColorTitle: '文字顏色' 53 | } ); 54 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colordialog/lang/en.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'colordialog', 'en', { 6 | clear: 'Clear', 7 | highlight: 'Highlight', 8 | options: 'Color Options', 9 | selected: 'Selected Color', 10 | title: 'Select color' 11 | } ); 12 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/colordialog/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'colordialog', 'zh-cn', { 6 | clear: '清除', 7 | highlight: '高亮', 8 | options: '颜色选项', 9 | selected: '选择颜色', 10 | title: '选择颜色' 11 | } ); 12 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/dialog/dialogDefinition.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/fakeobjects/images/spacer.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/fakeobjects/images/spacer.gif -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/font/lang/en.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'font', 'en', { 6 | fontSize: { 7 | label: 'Size', 8 | voiceLabel: 'Font Size', 9 | panelTitle: 'Font Size' 10 | }, 11 | label: 'Font', 12 | panelTitle: 'Font Name', 13 | voiceLabel: 'Font' 14 | } ); 15 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/font/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'font', 'zh-cn', { 6 | fontSize: { 7 | label: '大小', 8 | voiceLabel: '文字大小', 9 | panelTitle: '大小' 10 | }, 11 | label: '字体', 12 | panelTitle: '字体', 13 | voiceLabel: '字体' 14 | } ); 15 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/icons.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/icons_hidpi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/icons_hidpi.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/image/images/noimage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/image/images/noimage.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifyblock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifyblock.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifycenter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifycenter.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifyleft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifyleft.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifyright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/hidpi/justifyright.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/justifyblock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/justifyblock.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/justifycenter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/justifycenter.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/justifyleft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/justifyleft.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/icons/justifyright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/justify/icons/justifyright.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/lang/en.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'justify', 'en', { 6 | block: 'Justify', 7 | center: 'Center', 8 | left: 'Align Left', 9 | right: 'Align Right' 10 | } ); 11 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/justify/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang( 'justify', 'zh-cn', { 6 | block: '两端对齐', 7 | center: '居中', 8 | left: '左对齐', 9 | right: '右对齐' 10 | } ); 11 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/link/dialogs/anchor.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.dialog.add("anchor",function(c){var d=function(a){this._.selectedElement=a;this.setValueOf("info","txtName",a.data("cke-saved-name")||"")};return{title:c.lang.link.anchor.title,minWidth:300,minHeight:60,onOk:function(){var a=CKEDITOR.tools.trim(this.getValueOf("info","txtName")),a={id:a,name:a,"data-cke-saved-name":a};if(this._.selectedElement)this._.selectedElement.data("cke-realelement")?(a=c.document.createElement("a",{attributes:a}),c.createFakeElement(a,"cke_anchor","anchor").replace(this._.selectedElement)): 6 | this._.selectedElement.setAttributes(a);else{var b=c.getSelection(),b=b&&b.getRanges()[0];b.collapsed?(CKEDITOR.plugins.link.synAnchorSelector&&(a["class"]="cke_anchor_empty"),CKEDITOR.plugins.link.emptyAnchorFix&&(a.contenteditable="false",a["data-cke-editable"]=1),a=c.document.createElement("a",{attributes:a}),CKEDITOR.plugins.link.fakeAnchor&&(a=c.createFakeElement(a,"cke_anchor","anchor")),b.insertNode(a)):(CKEDITOR.env.ie&&9>CKEDITOR.env.version&&(a["class"]="cke_anchor"),a=new CKEDITOR.style({element:"a", 7 | attributes:a}),a.type=CKEDITOR.STYLE_INLINE,c.applyStyle(a))}},onHide:function(){delete this._.selectedElement},onShow:function(){var a=c.getSelection(),b=a.getSelectedElement();if(b)CKEDITOR.plugins.link.fakeAnchor?((a=CKEDITOR.plugins.link.tryRestoreFakeAnchor(c,b))&&d.call(this,a),this._.selectedElement=b):b.is("a")&&b.hasAttribute("name")&&d.call(this,b);else if(b=CKEDITOR.plugins.link.getSelectedLink(c))d.call(this,b),a.selectElement(b);this.getContentElement("info","txtName").focus()},contents:[{id:"info", 8 | label:c.lang.link.anchor.title,accessKey:"I",elements:[{type:"text",id:"txtName",label:c.lang.link.anchor.name,required:!0,validate:function(){return!this.getValue()?(alert(c.lang.link.anchor.errorName),!1):!0}}]}]}}); -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/link/images/anchor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/link/images/anchor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/link/images/hidpi/anchor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/link/images/hidpi/anchor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/magicline/images/hidpi/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/magicline/images/hidpi/icon.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/magicline/images/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/plugins/magicline/images/icon.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/scayt/LICENSE.md: -------------------------------------------------------------------------------- 1 | Software License Agreement 2 | ========================== 3 | 4 | **CKEditor SCAYT Plugin** 5 | Copyright © 2012, [CKSource](http://cksource.com) - Frederico Knabben. All rights reserved. 6 | 7 | Licensed under the terms of any of the following licenses at your choice: 8 | 9 | * GNU General Public License Version 2 or later (the "GPL"): 10 | http://www.gnu.org/licenses/gpl.html 11 | 12 | * GNU Lesser General Public License Version 2.1 or later (the "LGPL"): 13 | http://www.gnu.org/licenses/lgpl.html 14 | 15 | * Mozilla Public License Version 1.1 or later (the "MPL"): 16 | http://www.mozilla.org/MPL/MPL-1.1.html 17 | 18 | You are not required to, but if you want to explicitly declare the license you have chosen to be bound to when using, reproducing, modifying and distributing this software, just include a text file titled "legal.txt" in your version of this software, indicating your license choice. 19 | 20 | Sources of Intellectual Property Included in this plugin 21 | -------------------------------------------------------- 22 | 23 | Where not otherwise indicated, all plugin content is authored by CKSource engineers and consists of CKSource-owned intellectual property. In some specific instances, the plugin will incorporate work done by developers outside of CKSource with their express permission. 24 | 25 | Trademarks 26 | ---------- 27 | 28 | CKEditor is a trademark of CKSource - Frederico Knabben. All other brand and product names are trademarks, registered trademarks or service marks of their respective holders. 29 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/scayt/README.md: -------------------------------------------------------------------------------- 1 | CKEditor SCAYT Plugin 2 | ===================== 3 | 4 | This plugin brings Spell Check As You Type (SCAYT) into CKEditor. 5 | 6 | SCAYT is a "installation-less", using the web-services of [WebSpellChecker.net](http://www.webspellchecker.net/). It's an out of the box solution. 7 | 8 | Installation 9 | ------------ 10 | 11 | 1. Clone/copy this repository contents in a new "plugins/scayt" folder in your CKEditor installation. 12 | 2. Enable the "scayt" plugin in the CKEditor configuration file (config.js): 13 | 14 | config.extraPlugins = 'scayt'; 15 | 16 | That's all. SCAYT will appear on the editor toolbar and will be ready to use. 17 | 18 | License 19 | ------- 20 | 21 | Licensed under the terms of any of the following licenses at your choice: [GPL](http://www.gnu.org/licenses/gpl.html), [LGPL](http://www.gnu.org/licenses/lgpl.html) and [MPL](http://www.mozilla.org/MPL/MPL-1.1.html). 22 | 23 | See LICENSE.md for more information. 24 | 25 | Developed in cooperation with [WebSpellChecker.net](http://www.webspellchecker.net/). 26 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/scayt/dialogs/toolbar.css: -------------------------------------------------------------------------------- 1 | a 2 | { 3 | text-decoration:none; 4 | padding: 2px 4px 4px 6px; 5 | display : block; 6 | border-width: 1px; 7 | border-style: solid; 8 | margin : 0px; 9 | } 10 | 11 | a.cke_scayt_toogle:hover, 12 | a.cke_scayt_toogle:focus, 13 | a.cke_scayt_toogle:active 14 | { 15 | border-color: #316ac5; 16 | background-color: #dff1ff; 17 | color : #000; 18 | cursor: pointer; 19 | margin : 0px; 20 | } 21 | a.cke_scayt_toogle { 22 | color : #316ac5; 23 | border-color: #fff; 24 | } 25 | .scayt_enabled a.cke_scayt_item { 26 | color : #316ac5; 27 | border-color: #fff; 28 | margin : 0px; 29 | } 30 | .scayt_disabled a.cke_scayt_item { 31 | color : gray; 32 | border-color : #fff; 33 | } 34 | .scayt_enabled a.cke_scayt_item:hover, 35 | .scayt_enabled a.cke_scayt_item:focus, 36 | .scayt_enabled a.cke_scayt_item:active 37 | { 38 | border-color: #316ac5; 39 | background-color: #dff1ff; 40 | color : #000; 41 | cursor: pointer; 42 | } 43 | .scayt_disabled a.cke_scayt_item:hover, 44 | .scayt_disabled a.cke_scayt_item:focus, 45 | .scayt_disabled a.cke_scayt_item:active 46 | { 47 | border-color: gray; 48 | background-color: #dff1ff; 49 | color : gray; 50 | cursor: no-drop; 51 | } 52 | .cke_scayt_set_on, .cke_scayt_set_off 53 | { 54 | display: none; 55 | } 56 | .scayt_enabled .cke_scayt_set_on 57 | { 58 | display: none; 59 | } 60 | .scayt_disabled .cke_scayt_set_on 61 | { 62 | display: inline; 63 | } 64 | .scayt_disabled .cke_scayt_set_off 65 | { 66 | display: none; 67 | } 68 | .scayt_enabled .cke_scayt_set_off 69 | { 70 | display: inline; 71 | } 72 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/specialchar/dialogs/lang/_translationstatus.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 2 | For licensing, see LICENSE.md or http://ckeditor.com/license 3 | 4 | cs.js Found: 118 Missing: 0 5 | cy.js Found: 118 Missing: 0 6 | de.js Found: 118 Missing: 0 7 | el.js Found: 16 Missing: 102 8 | eo.js Found: 118 Missing: 0 9 | et.js Found: 31 Missing: 87 10 | fa.js Found: 24 Missing: 94 11 | fi.js Found: 23 Missing: 95 12 | fr.js Found: 118 Missing: 0 13 | hr.js Found: 23 Missing: 95 14 | it.js Found: 118 Missing: 0 15 | nb.js Found: 118 Missing: 0 16 | nl.js Found: 118 Missing: 0 17 | no.js Found: 118 Missing: 0 18 | tr.js Found: 118 Missing: 0 19 | ug.js Found: 39 Missing: 79 20 | zh-cn.js Found: 118 Missing: 0 21 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/specialchar/dialogs/lang/ja.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang("specialchar","ja",{euro:"ユーロ記号",lsquo:"左シングル引用符",rsquo:"右シングル引用符",ldquo:"左ダブル引用符",rdquo:"右ダブル引用符",ndash:"半角ダッシュ",mdash:"全角ダッシュ",iexcl:"逆さ感嘆符",cent:"セント記号",pound:"ポンド記号",curren:"通貨記号",yen:"円記号",brvbar:"上下に分かれた縦棒",sect:"節記号",uml:"分音記号(ウムラウト)",copy:"著作権表示記号",ordf:"女性序数標識",laquo:" 始め二重山括弧引用記号",not:"論理否定記号",reg:"登録商標記号",macr:"長音符",deg:"度記号",sup2:"上つき2, 2乗",sup3:"上つき3, 3乗",acute:"揚音符",micro:"ミクロン記号",para:"段落記号",middot:"中黒",cedil:"セディラ",sup1:"上つき1",ordm:"男性序数標識",raquo:"終わり二重山括弧引用記号", 6 | frac14:"四分の一",frac12:"二分の一",frac34:"四分の三",iquest:"逆疑問符",Agrave:"抑音符つき大文字A",Aacute:"揚音符つき大文字A",Acirc:"曲折アクセントつき大文字A",Atilde:"チルダつき大文字A",Auml:"分音記号つき大文字A",Aring:"リングつき大文字A",AElig:"AとEの合字",Ccedil:"セディラつき大文字C",Egrave:"抑音符つき大文字E",Eacute:"揚音符つき大文字E",Ecirc:"曲折アクセントつき大文字E",Euml:"分音記号つき大文字E",Igrave:"抑音符つき大文字I",Iacute:"揚音符つき大文字I",Icirc:"曲折アクセントつき大文字I",Iuml:"分音記号つき大文字I",ETH:"[アイスランド語]大文字ETH",Ntilde:"チルダつき大文字N",Ograve:"抑音符つき大文字O",Oacute:"揚音符つき大文字O",Ocirc:"曲折アクセントつき大文字O",Otilde:"チルダつき大文字O",Ouml:" 分音記号つき大文字O", 7 | times:"乗算記号",Oslash:"打ち消し線つき大文字O",Ugrave:"抑音符つき大文字U",Uacute:"揚音符つき大文字U",Ucirc:"曲折アクセントつき大文字U",Uuml:"分音記号つき大文字U",Yacute:"揚音符つき大文字Y",THORN:"[アイスランド語]大文字THORN",szlig:"ドイツ語エスツェット",agrave:"抑音符つき小文字a",aacute:"揚音符つき小文字a",acirc:"曲折アクセントつき小文字a",atilde:"チルダつき小文字a",auml:"分音記号つき小文字a",aring:"リングつき小文字a",aelig:"aとeの合字",ccedil:"セディラつき小文字c",egrave:"抑音符つき小文字e",eacute:"揚音符つき小文字e",ecirc:"曲折アクセントつき小文字e",euml:"分音記号つき小文字e",igrave:"抑音符つき小文字i",iacute:"揚音符つき小文字i",icirc:"曲折アクセントつき小文字i",iuml:"分音記号つき小文字i",eth:"アイスランド語小文字eth", 8 | ntilde:"チルダつき小文字n",ograve:"抑音符つき小文字o",oacute:"揚音符つき小文字o",ocirc:"曲折アクセントつき小文字o",otilde:"チルダつき小文字o",ouml:"分音記号つき小文字o",divide:"除算記号",oslash:"打ち消し線つき小文字o",ugrave:"抑音符つき小文字u",uacute:"揚音符つき小文字u",ucirc:"曲折アクセントつき小文字u",uuml:"分音記号つき小文字u",yacute:"揚音符つき小文字y",thorn:"アイスランド語小文字thorn",yuml:"分音記号つき小文字y",OElig:"OとEの合字",oelig:"oとeの合字",372:"曲折アクセントつき大文字W",374:"曲折アクセントつき大文字Y",373:"曲折アクセントつき小文字w",375:"曲折アクセントつき小文字y",sbquo:"シングル下引用符",8219:"左右逆の左引用符",bdquo:"ダブル下引用符",hellip:"三点リーダ",trade:"商標記号",9658:"右黒三角ポインタ",bull:"黒丸", 9 | rarr:"右矢印",rArr:"右二重矢印",hArr:"左右二重矢印",diams:"ダイヤ",asymp:"漸近"}); -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/specialchar/dialogs/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.md or http://ckeditor.com/license 4 | */ 5 | CKEDITOR.plugins.setLang("specialchar","zh-cn",{euro:"欧元符号",lsquo:"左单引号",rsquo:"右单引号",ldquo:"左双引号",rdquo:"右双引号",ndash:"短划线",mdash:"长划线",iexcl:"竖翻叹号",cent:"分币符号",pound:"英镑符号",curren:"货币符号",yen:"日元符号",brvbar:"间断条",sect:"节标记",uml:"分音符",copy:"版权所有标记",ordf:"阴性顺序指示符",laquo:"左指双尖引号",not:"非标记",reg:"注册标记",macr:"长音符",deg:"度标记",sup2:"上标二",sup3:"上标三",acute:"锐音符",micro:"微符",para:"段落标记",middot:"中间点",cedil:"下加符",sup1:"上标一",ordm:"阳性顺序指示符",raquo:"右指双尖引号",frac14:"普通分数四分之一",frac12:"普通分数二分之一",frac34:"普通分数四分之三",iquest:"竖翻问号", 6 | Agrave:"带抑音符的拉丁文大写字母 A",Aacute:"带锐音符的拉丁文大写字母 A",Acirc:"带扬抑符的拉丁文大写字母 A",Atilde:"带颚化符的拉丁文大写字母 A",Auml:"带分音符的拉丁文大写字母 A",Aring:"带上圆圈的拉丁文大写字母 A",AElig:"拉丁文大写字母 Ae",Ccedil:"带下加符的拉丁文大写字母 C",Egrave:"带抑音符的拉丁文大写字母 E",Eacute:"带锐音符的拉丁文大写字母 E",Ecirc:"带扬抑符的拉丁文大写字母 E",Euml:"带分音符的拉丁文大写字母 E",Igrave:"带抑音符的拉丁文大写字母 I",Iacute:"带锐音符的拉丁文大写字母 I",Icirc:"带扬抑符的拉丁文大写字母 I",Iuml:"带分音符的拉丁文大写字母 I",ETH:"拉丁文大写字母 Eth",Ntilde:"带颚化符的拉丁文大写字母 N",Ograve:"带抑音符的拉丁文大写字母 O",Oacute:"带锐音符的拉丁文大写字母 O",Ocirc:"带扬抑符的拉丁文大写字母 O",Otilde:"带颚化符的拉丁文大写字母 O", 7 | Ouml:"带分音符的拉丁文大写字母 O",times:"乘号",Oslash:"带粗线的拉丁文大写字母 O",Ugrave:"带抑音符的拉丁文大写字母 U",Uacute:"带锐音符的拉丁文大写字母 U",Ucirc:"带扬抑符的拉丁文大写字母 U",Uuml:"带分音符的拉丁文大写字母 U",Yacute:"带抑音符的拉丁文大写字母 Y",THORN:"拉丁文大写字母 Thorn",szlig:"拉丁文小写字母清音 S",agrave:"带抑音符的拉丁文小写字母 A",aacute:"带锐音符的拉丁文小写字母 A",acirc:"带扬抑符的拉丁文小写字母 A",atilde:"带颚化符的拉丁文小写字母 A",auml:"带分音符的拉丁文小写字母 A",aring:"带上圆圈的拉丁文小写字母 A",aelig:"拉丁文小写字母 Ae",ccedil:"带下加符的拉丁文小写字母 C",egrave:"带抑音符的拉丁文小写字母 E",eacute:"带锐音符的拉丁文小写字母 E",ecirc:"带扬抑符的拉丁文小写字母 E",euml:"带分音符的拉丁文小写字母 E",igrave:"带抑音符的拉丁文小写字母 I", 8 | iacute:"带锐音符的拉丁文小写字母 I",icirc:"带扬抑符的拉丁文小写字母 I",iuml:"带分音符的拉丁文小写字母 I",eth:"拉丁文小写字母 Eth",ntilde:"带颚化符的拉丁文小写字母 N",ograve:"带抑音符的拉丁文小写字母 O",oacute:"带锐音符的拉丁文小写字母 O",ocirc:"带扬抑符的拉丁文小写字母 O",otilde:"带颚化符的拉丁文小写字母 O",ouml:"带分音符的拉丁文小写字母 O",divide:"除号",oslash:"带粗线的拉丁文小写字母 O",ugrave:"带抑音符的拉丁文小写字母 U",uacute:"带锐音符的拉丁文小写字母 U",ucirc:"带扬抑符的拉丁文小写字母 U",uuml:"带分音符的拉丁文小写字母 U",yacute:"带抑音符的拉丁文小写字母 Y",thorn:"拉丁文小写字母 Thorn",yuml:"带分音符的拉丁文小写字母 Y",OElig:"拉丁文大写连字 Oe",oelig:"拉丁文小写连字 Oe",372:"带扬抑符的拉丁文大写字母 W",374:"带扬抑符的拉丁文大写字母 Y", 9 | 373:"带扬抑符的拉丁文小写字母 W",375:"带扬抑符的拉丁文小写字母 Y",sbquo:"单下 9 形引号",8219:"单高横翻 9 形引号",bdquo:"双下 9 形引号",hellip:"水平省略号",trade:"商标标志",9658:"实心右指指针",bull:"加重号",rarr:"向右箭头",rArr:"向右双线箭头",hArr:"左右双线箭头",diams:"实心方块纸牌",asymp:"约等于"}); -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/wsc/LICENSE.md: -------------------------------------------------------------------------------- 1 | Software License Agreement 2 | ========================== 3 | 4 | **CKEditor WSC Plugin** 5 | Copyright © 2012, [CKSource](http://cksource.com) - Frederico Knabben. All rights reserved. 6 | 7 | Licensed under the terms of any of the following licenses at your choice: 8 | 9 | * GNU General Public License Version 2 or later (the "GPL"): 10 | http://www.gnu.org/licenses/gpl.html 11 | 12 | * GNU Lesser General Public License Version 2.1 or later (the "LGPL"): 13 | http://www.gnu.org/licenses/lgpl.html 14 | 15 | * Mozilla Public License Version 1.1 or later (the "MPL"): 16 | http://www.mozilla.org/MPL/MPL-1.1.html 17 | 18 | You are not required to, but if you want to explicitly declare the license you have chosen to be bound to when using, reproducing, modifying and distributing this software, just include a text file titled "legal.txt" in your version of this software, indicating your license choice. 19 | 20 | Sources of Intellectual Property Included in this plugin 21 | -------------------------------------------------------- 22 | 23 | Where not otherwise indicated, all plugin content is authored by CKSource engineers and consists of CKSource-owned intellectual property. In some specific instances, the plugin will incorporate work done by developers outside of CKSource with their express permission. 24 | 25 | Trademarks 26 | ---------- 27 | 28 | CKEditor is a trademark of CKSource - Frederico Knabben. All other brand and product names are trademarks, registered trademarks or service marks of their respective holders. 29 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/wsc/README.md: -------------------------------------------------------------------------------- 1 | CKEditor WebSpellChecker Plugin 2 | =============================== 3 | 4 | This plugin brings Web Spell Checker (WSC) into CKEditor. 5 | 6 | WSC is "installation-less", using the web-services of [WebSpellChecker.net](http://www.webspellchecker.net/). It's an out of the box solution. 7 | 8 | Installation 9 | ------------ 10 | 11 | 1. Clone/copy this repository contents in a new "plugins/wsc" folder in your CKEditor installation. 12 | 2. Enable the "wsc" plugin in the CKEditor configuration file (config.js): 13 | 14 | config.extraPlugins = 'wsc'; 15 | 16 | That's all. WSC will appear on the editor toolbar and will be ready to use. 17 | 18 | License 19 | ------- 20 | 21 | Licensed under the terms of any of the following licenses at your choice: [GPL](http://www.gnu.org/licenses/gpl.html), [LGPL](http://www.gnu.org/licenses/lgpl.html) and [MPL](http://www.mozilla.org/MPL/MPL-1.1.html). 22 | 23 | See LICENSE.md for more information. 24 | 25 | Developed in cooperation with [WebSpellChecker.net](http://www.webspellchecker.net/). 26 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/wsc/dialogs/ciframe.html: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 64 | 65 |

66 | 67 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/wsc/dialogs/tmpFrameset.html: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/plugins/wsc/dialogs/wsc.css: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. 3 | For licensing, see LICENSE.html or http://ckeditor.com/license 4 | */ 5 | 6 | html, body 7 | { 8 | background-color: transparent; 9 | margin: 0px; 10 | padding: 0px; 11 | } 12 | 13 | body 14 | { 15 | padding: 10px; 16 | } 17 | 18 | body, td, input, select, textarea 19 | { 20 | font-size: 11px; 21 | font-family: 'Microsoft Sans Serif' , Arial, Helvetica, Verdana; 22 | } 23 | 24 | .midtext 25 | { 26 | padding:0px; 27 | margin:10px; 28 | } 29 | 30 | .midtext p 31 | { 32 | padding:0px; 33 | margin:10px; 34 | } 35 | 36 | .Button 37 | { 38 | border: #737357 1px solid; 39 | color: #3b3b1f; 40 | background-color: #c7c78f; 41 | } 42 | 43 | .PopupTabArea 44 | { 45 | color: #737357; 46 | background-color: #e3e3c7; 47 | } 48 | 49 | .PopupTitleBorder 50 | { 51 | border-bottom: #d5d59d 1px solid; 52 | } 53 | .PopupTabEmptyArea 54 | { 55 | padding-left: 10px; 56 | border-bottom: #d5d59d 1px solid; 57 | } 58 | 59 | .PopupTab, .PopupTabSelected 60 | { 61 | border-right: #d5d59d 1px solid; 62 | border-top: #d5d59d 1px solid; 63 | border-left: #d5d59d 1px solid; 64 | padding: 3px 5px 3px 5px; 65 | color: #737357; 66 | } 67 | 68 | .PopupTab 69 | { 70 | margin-top: 1px; 71 | border-bottom: #d5d59d 1px solid; 72 | cursor: pointer; 73 | } 74 | 75 | .PopupTabSelected 76 | { 77 | font-weight: bold; 78 | cursor: default; 79 | padding-top: 4px; 80 | border-bottom: #f1f1e3 1px solid; 81 | background-color: #f1f1e3; 82 | } 83 | -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/icons.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/icons_hidpi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/icons_hidpi.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/arrow.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/close.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/close.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/lock-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/lock-open.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/lock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/lock.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/refresh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/hidpi/refresh.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/lock-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/lock-open.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/lock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/lock.png -------------------------------------------------------------------------------- /wtxlog/static/admin/ckeditor/skins/moono/images/refresh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/ckeditor/skins/moono/images/refresh.png -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/dialog/dialog.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-dialog { 2 | position: absolute; 3 | left: 0; right: 0; 4 | background: white; 5 | z-index: 15; 6 | padding: .1em .8em; 7 | overflow: hidden; 8 | color: #333; 9 | } 10 | 11 | .CodeMirror-dialog-top { 12 | border-bottom: 1px solid #eee; 13 | top: 0; 14 | } 15 | 16 | .CodeMirror-dialog-bottom { 17 | border-top: 1px solid #eee; 18 | bottom: 0; 19 | } 20 | 21 | .CodeMirror-dialog input { 22 | border: none; 23 | outline: none; 24 | background: transparent; 25 | width: 20em; 26 | color: inherit; 27 | font-family: monospace; 28 | } 29 | 30 | .CodeMirror-dialog button { 31 | font-size: 70%; 32 | } 33 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/display/fullscreen.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-fullscreen { 2 | position: fixed; 3 | top: 0; left: 0; right: 0; bottom: 0; 4 | height: auto; 5 | z-index: 9; 6 | } 7 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/display/fullscreen.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | CodeMirror.defineOption("fullScreen", false, function(cm, val, old) { 15 | if (old == CodeMirror.Init) old = false; 16 | if (!old == !val) return; 17 | if (val) setFullscreen(cm); 18 | else setNormal(cm); 19 | }); 20 | 21 | function setFullscreen(cm) { 22 | var wrap = cm.getWrapperElement(); 23 | cm.state.fullScreenRestore = {scrollTop: window.pageYOffset, scrollLeft: window.pageXOffset, 24 | width: wrap.style.width, height: wrap.style.height}; 25 | wrap.style.width = ""; 26 | wrap.style.height = "auto"; 27 | wrap.className += " CodeMirror-fullscreen"; 28 | document.documentElement.style.overflow = "hidden"; 29 | cm.refresh(); 30 | } 31 | 32 | function setNormal(cm) { 33 | var wrap = cm.getWrapperElement(); 34 | wrap.className = wrap.className.replace(/\s*CodeMirror-fullscreen\b/, ""); 35 | document.documentElement.style.overflow = ""; 36 | var info = cm.state.fullScreenRestore; 37 | wrap.style.width = info.width; wrap.style.height = info.height; 38 | window.scrollTo(info.scrollLeft, info.scrollTop); 39 | cm.refresh(); 40 | } 41 | }); 42 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/display/placeholder.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | CodeMirror.defineOption("placeholder", "", function(cm, val, old) { 13 | var prev = old && old != CodeMirror.Init; 14 | if (val && !prev) { 15 | cm.on("blur", onBlur); 16 | cm.on("change", onChange); 17 | onChange(cm); 18 | } else if (!val && prev) { 19 | cm.off("blur", onBlur); 20 | cm.off("change", onChange); 21 | clearPlaceholder(cm); 22 | var wrapper = cm.getWrapperElement(); 23 | wrapper.className = wrapper.className.replace(" CodeMirror-empty", ""); 24 | } 25 | 26 | if (val && !cm.hasFocus()) onBlur(cm); 27 | }); 28 | 29 | function clearPlaceholder(cm) { 30 | if (cm.state.placeholder) { 31 | cm.state.placeholder.parentNode.removeChild(cm.state.placeholder); 32 | cm.state.placeholder = null; 33 | } 34 | } 35 | function setPlaceholder(cm) { 36 | clearPlaceholder(cm); 37 | var elt = cm.state.placeholder = document.createElement("pre"); 38 | elt.style.cssText = "height: 0; overflow: visible"; 39 | elt.className = "CodeMirror-placeholder"; 40 | elt.appendChild(document.createTextNode(cm.getOption("placeholder"))); 41 | cm.display.lineSpace.insertBefore(elt, cm.display.lineSpace.firstChild); 42 | } 43 | 44 | function onBlur(cm) { 45 | if (isEmpty(cm)) setPlaceholder(cm); 46 | } 47 | function onChange(cm) { 48 | var wrapper = cm.getWrapperElement(), empty = isEmpty(cm); 49 | wrapper.className = wrapper.className.replace(" CodeMirror-empty", "") + (empty ? " CodeMirror-empty" : ""); 50 | 51 | if (empty) setPlaceholder(cm); 52 | else clearPlaceholder(cm); 53 | } 54 | 55 | function isEmpty(cm) { 56 | return (cm.lineCount() === 1) && (cm.getLine(0) === ""); 57 | } 58 | }); 59 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/display/rulers.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | CodeMirror.defineOption("rulers", false, function(cm, val, old) { 15 | if (old && old != CodeMirror.Init) { 16 | clearRulers(cm); 17 | cm.off("refresh", refreshRulers); 18 | } 19 | if (val && val.length) { 20 | setRulers(cm); 21 | cm.on("refresh", refreshRulers); 22 | } 23 | }); 24 | 25 | function clearRulers(cm) { 26 | for (var i = cm.display.lineSpace.childNodes.length - 1; i >= 0; i--) { 27 | var node = cm.display.lineSpace.childNodes[i]; 28 | if (/(^|\s)CodeMirror-ruler($|\s)/.test(node.className)) 29 | node.parentNode.removeChild(node); 30 | } 31 | } 32 | 33 | function setRulers(cm) { 34 | var val = cm.getOption("rulers"); 35 | var cw = cm.defaultCharWidth(); 36 | var left = cm.charCoords(CodeMirror.Pos(cm.firstLine(), 0), "div").left; 37 | var minH = cm.display.scroller.offsetHeight + 30; 38 | for (var i = 0; i < val.length; i++) { 39 | var elt = document.createElement("div"); 40 | elt.className = "CodeMirror-ruler"; 41 | var col, cls = null, conf = val[i]; 42 | if (typeof conf == "number") { 43 | col = conf; 44 | } else { 45 | col = conf.column; 46 | if (conf.className) elt.className += " " + conf.className; 47 | if (conf.color) elt.style.borderColor = conf.color; 48 | if (conf.lineStyle) elt.style.borderLeftStyle = conf.lineStyle; 49 | if (conf.width) elt.style.borderLeftWidth = conf.width; 50 | cls = val[i].className; 51 | } 52 | elt.style.left = (left + col * cw) + "px"; 53 | elt.style.top = "-50px"; 54 | elt.style.bottom = "-20px"; 55 | elt.style.minHeight = minH + "px"; 56 | cm.display.lineSpace.insertBefore(elt, cm.display.cursorDiv); 57 | } 58 | } 59 | 60 | function refreshRulers(cm) { 61 | clearRulers(cm); 62 | setRulers(cm); 63 | } 64 | }); 65 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/edit/continuelist.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | var listRE = /^(\s*)([> ]+|[*+-]|(\d+)\.)(\s+)/, 15 | emptyListRE = /^(\s*)([> ]+|[*+-]|(\d+)\.)(\s*)$/, 16 | unorderedBullets = "*+-"; 17 | 18 | CodeMirror.commands.newlineAndIndentContinueMarkdownList = function(cm) { 19 | if (cm.getOption("disableInput")) return CodeMirror.Pass; 20 | var ranges = cm.listSelections(), replacements = []; 21 | for (var i = 0; i < ranges.length; i++) { 22 | var pos = ranges[i].head, match; 23 | var eolState = cm.getStateAfter(pos.line); 24 | var inList = eolState.list !== false; 25 | var inQuote = eolState.quote !== false; 26 | 27 | if (!ranges[i].empty() || (!inList && !inQuote) || !(match = cm.getLine(pos.line).match(listRE))) { 28 | cm.execCommand("newlineAndIndent"); 29 | return; 30 | } 31 | if (cm.getLine(pos.line).match(emptyListRE)) { 32 | cm.replaceRange("", { 33 | line: pos.line, ch: 0 34 | }, { 35 | line: pos.line, ch: pos.ch + 1 36 | }); 37 | replacements[i] = "\n"; 38 | 39 | } else { 40 | var indent = match[1], after = match[4]; 41 | var bullet = unorderedBullets.indexOf(match[2]) >= 0 || match[2].indexOf(">") >= 0 42 | ? match[2] 43 | : (parseInt(match[3], 10) + 1) + "."; 44 | 45 | replacements[i] = "\n" + indent + bullet + after; 46 | } 47 | } 48 | 49 | cm.replaceSelections(replacements); 50 | }; 51 | }); 52 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/edit/trailingspace.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | CodeMirror.defineOption("showTrailingSpace", false, function(cm, val, prev) { 13 | if (prev == CodeMirror.Init) prev = false; 14 | if (prev && !val) 15 | cm.removeOverlay("trailingspace"); 16 | else if (!prev && val) 17 | cm.addOverlay({ 18 | token: function(stream) { 19 | for (var l = stream.string.length, i = l; i && /\s/.test(stream.string.charAt(i - 1)); --i) {} 20 | if (i > stream.pos) { stream.pos = i; return null; } 21 | stream.pos = l; 22 | return "trailingspace"; 23 | }, 24 | name: "trailingspace" 25 | }); 26 | }); 27 | }); 28 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/fold/comment-fold.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | CodeMirror.registerGlobalHelper("fold", "comment", function(mode) { 15 | return mode.blockCommentStart && mode.blockCommentEnd; 16 | }, function(cm, start) { 17 | var mode = cm.getModeAt(start), startToken = mode.blockCommentStart, endToken = mode.blockCommentEnd; 18 | if (!startToken || !endToken) return; 19 | var line = start.line, lineText = cm.getLine(line); 20 | 21 | var startCh; 22 | for (var at = start.ch, pass = 0;;) { 23 | var found = at <= 0 ? -1 : lineText.lastIndexOf(startToken, at - 1); 24 | if (found == -1) { 25 | if (pass == 1) return; 26 | pass = 1; 27 | at = lineText.length; 28 | continue; 29 | } 30 | if (pass == 1 && found < start.ch) return; 31 | if (/comment/.test(cm.getTokenTypeAt(CodeMirror.Pos(line, found + 1)))) { 32 | startCh = found + startToken.length; 33 | break; 34 | } 35 | at = found - 1; 36 | } 37 | 38 | var depth = 1, lastLine = cm.lastLine(), end, endCh; 39 | outer: for (var i = line; i <= lastLine; ++i) { 40 | var text = cm.getLine(i), pos = i == line ? startCh : 0; 41 | for (;;) { 42 | var nextOpen = text.indexOf(startToken, pos), nextClose = text.indexOf(endToken, pos); 43 | if (nextOpen < 0) nextOpen = text.length; 44 | if (nextClose < 0) nextClose = text.length; 45 | pos = Math.min(nextOpen, nextClose); 46 | if (pos == text.length) break; 47 | if (pos == nextOpen) ++depth; 48 | else if (!--depth) { end = i; endCh = pos; break outer; } 49 | ++pos; 50 | } 51 | } 52 | if (end == null || line == end && endCh == startCh) return; 53 | return {from: CodeMirror.Pos(line, startCh), 54 | to: CodeMirror.Pos(end, endCh)}; 55 | }); 56 | 57 | }); 58 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/fold/foldgutter.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-foldmarker { 2 | color: blue; 3 | text-shadow: #b9f 1px 1px 2px, #b9f -1px -1px 2px, #b9f 1px -1px 2px, #b9f -1px 1px 2px; 4 | font-family: arial; 5 | line-height: .3; 6 | cursor: pointer; 7 | } 8 | .CodeMirror-foldgutter { 9 | width: .7em; 10 | } 11 | .CodeMirror-foldgutter-open, 12 | .CodeMirror-foldgutter-folded { 13 | cursor: pointer; 14 | } 15 | .CodeMirror-foldgutter-open:after { 16 | content: "\25BE"; 17 | } 18 | .CodeMirror-foldgutter-folded:after { 19 | content: "\25B8"; 20 | } 21 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/fold/indent-fold.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | CodeMirror.registerHelper("fold", "indent", function(cm, start) { 15 | var tabSize = cm.getOption("tabSize"), firstLine = cm.getLine(start.line); 16 | if (!/\S/.test(firstLine)) return; 17 | var getIndent = function(line) { 18 | return CodeMirror.countColumn(line, null, tabSize); 19 | }; 20 | var myIndent = getIndent(firstLine); 21 | var lastLineInFold = null; 22 | // Go through lines until we find a line that definitely doesn't belong in 23 | // the block we're folding, or to the end. 24 | for (var i = start.line + 1, end = cm.lastLine(); i <= end; ++i) { 25 | var curLine = cm.getLine(i); 26 | var curIndent = getIndent(curLine); 27 | if (curIndent > myIndent) { 28 | // Lines with a greater indent are considered part of the block. 29 | lastLineInFold = i; 30 | } else if (!/\S/.test(curLine)) { 31 | // Empty lines might be breaks within the block we're trying to fold. 32 | } else { 33 | // A non-empty line at an indent equal to or less than ours marks the 34 | // start of another block. 35 | break; 36 | } 37 | } 38 | if (lastLineInFold) return { 39 | from: CodeMirror.Pos(start.line, firstLine.length), 40 | to: CodeMirror.Pos(lastLineInFold, cm.getLine(lastLineInFold).length) 41 | }; 42 | }); 43 | 44 | }); 45 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/fold/markdown-fold.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | CodeMirror.registerHelper("fold", "markdown", function(cm, start) { 15 | var maxDepth = 100; 16 | 17 | function isHeader(lineNo) { 18 | var tokentype = cm.getTokenTypeAt(CodeMirror.Pos(lineNo, 0)); 19 | return tokentype && /\bheader\b/.test(tokentype); 20 | } 21 | 22 | function headerLevel(lineNo, line, nextLine) { 23 | var match = line && line.match(/^#+/); 24 | if (match && isHeader(lineNo)) return match[0].length; 25 | match = nextLine && nextLine.match(/^[=\-]+\s*$/); 26 | if (match && isHeader(lineNo + 1)) return nextLine[0] == "=" ? 1 : 2; 27 | return maxDepth; 28 | } 29 | 30 | var firstLine = cm.getLine(start.line), nextLine = cm.getLine(start.line + 1); 31 | var level = headerLevel(start.line, firstLine, nextLine); 32 | if (level === maxDepth) return undefined; 33 | 34 | var lastLineNo = cm.lastLine(); 35 | var end = start.line, nextNextLine = cm.getLine(end + 2); 36 | while (end < lastLineNo) { 37 | if (headerLevel(end + 1, nextLine, nextNextLine) <= level) break; 38 | ++end; 39 | nextLine = nextNextLine; 40 | nextNextLine = cm.getLine(end + 2); 41 | } 42 | 43 | return { 44 | from: CodeMirror.Pos(start.line, firstLine.length), 45 | to: CodeMirror.Pos(end, cm.getLine(end).length) 46 | }; 47 | }); 48 | 49 | }); 50 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/hint/anyword-hint.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | var WORD = /[\w$]+/, RANGE = 500; 15 | 16 | CodeMirror.registerHelper("hint", "anyword", function(editor, options) { 17 | var word = options && options.word || WORD; 18 | var range = options && options.range || RANGE; 19 | var cur = editor.getCursor(), curLine = editor.getLine(cur.line); 20 | var start = cur.ch, end = start; 21 | while (end < curLine.length && word.test(curLine.charAt(end))) ++end; 22 | while (start && word.test(curLine.charAt(start - 1))) --start; 23 | var curWord = start != end && curLine.slice(start, end); 24 | 25 | var list = [], seen = {}; 26 | var re = new RegExp(word.source, "g"); 27 | for (var dir = -1; dir <= 1; dir += 2) { 28 | var line = cur.line, endLine = Math.min(Math.max(line + dir * range, editor.firstLine()), editor.lastLine()) + dir; 29 | for (; line != endLine; line += dir) { 30 | var text = editor.getLine(line), m; 31 | while (m = re.exec(text)) { 32 | if (line == cur.line && m[0] === curWord) continue; 33 | if ((!curWord || m[0].lastIndexOf(curWord, 0) == 0) && !Object.prototype.hasOwnProperty.call(seen, m[0])) { 34 | seen[m[0]] = true; 35 | list.push(m[0]); 36 | } 37 | } 38 | } 39 | } 40 | return {list: list, from: CodeMirror.Pos(cur.line, start), to: CodeMirror.Pos(cur.line, end)}; 41 | }); 42 | }); 43 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/hint/css-hint.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror"), require("../../mode/css/css")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror", "../../mode/css/css"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | var pseudoClasses = {link: 1, visited: 1, active: 1, hover: 1, focus: 1, 15 | "first-letter": 1, "first-line": 1, "first-child": 1, 16 | before: 1, after: 1, lang: 1}; 17 | 18 | CodeMirror.registerHelper("hint", "css", function(cm) { 19 | var cur = cm.getCursor(), token = cm.getTokenAt(cur); 20 | var inner = CodeMirror.innerMode(cm.getMode(), token.state); 21 | if (inner.mode.name != "css") return; 22 | 23 | var word = token.string, start = token.start, end = token.end; 24 | if (/[^\w$_-]/.test(word)) { 25 | word = ""; start = end = cur.ch; 26 | } 27 | 28 | var spec = CodeMirror.resolveMode("text/css"); 29 | 30 | var result = []; 31 | function add(keywords) { 32 | for (var name in keywords) 33 | if (!word || name.lastIndexOf(word, 0) == 0) 34 | result.push(name); 35 | } 36 | 37 | var st = inner.state.state; 38 | if (st == "pseudo" || token.type == "variable-3") { 39 | add(pseudoClasses); 40 | } else if (st == "block" || st == "maybeprop") { 41 | add(spec.propertyKeywords); 42 | } else if (st == "prop" || st == "parens" || st == "at" || st == "params") { 43 | add(spec.valueKeywords); 44 | add(spec.colorKeywords); 45 | } else if (st == "media" || st == "media_parens") { 46 | add(spec.mediaTypes); 47 | add(spec.mediaFeatures); 48 | } 49 | 50 | if (result.length) return { 51 | list: result, 52 | from: CodeMirror.Pos(cur.line, start), 53 | to: CodeMirror.Pos(cur.line, end) 54 | }; 55 | }); 56 | }); 57 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/hint/show-hint.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-hints { 2 | position: absolute; 3 | z-index: 10; 4 | overflow: hidden; 5 | list-style: none; 6 | 7 | margin: 0; 8 | padding: 2px; 9 | 10 | -webkit-box-shadow: 2px 3px 5px rgba(0,0,0,.2); 11 | -moz-box-shadow: 2px 3px 5px rgba(0,0,0,.2); 12 | box-shadow: 2px 3px 5px rgba(0,0,0,.2); 13 | border-radius: 3px; 14 | border: 1px solid silver; 15 | 16 | background: white; 17 | font-size: 90%; 18 | font-family: monospace; 19 | 20 | max-height: 20em; 21 | overflow-y: auto; 22 | } 23 | 24 | .CodeMirror-hint { 25 | margin: 0; 26 | padding: 0 4px; 27 | border-radius: 2px; 28 | max-width: 19em; 29 | overflow: hidden; 30 | white-space: pre; 31 | color: black; 32 | cursor: pointer; 33 | } 34 | 35 | li.CodeMirror-hint-active { 36 | background: #08f; 37 | color: white; 38 | } 39 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/lint/coffeescript-lint.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | // Depends on coffeelint.js from http://www.coffeelint.org/js/coffeelint.js 5 | 6 | // declare global: coffeelint 7 | 8 | (function(mod) { 9 | if (typeof exports == "object" && typeof module == "object") // CommonJS 10 | mod(require("../../lib/codemirror")); 11 | else if (typeof define == "function" && define.amd) // AMD 12 | define(["../../lib/codemirror"], mod); 13 | else // Plain browser env 14 | mod(CodeMirror); 15 | })(function(CodeMirror) { 16 | "use strict"; 17 | 18 | CodeMirror.registerHelper("lint", "coffeescript", function(text) { 19 | var found = []; 20 | var parseError = function(err) { 21 | var loc = err.lineNumber; 22 | found.push({from: CodeMirror.Pos(loc-1, 0), 23 | to: CodeMirror.Pos(loc, 0), 24 | severity: err.level, 25 | message: err.message}); 26 | }; 27 | try { 28 | var res = coffeelint.lint(text); 29 | for(var i = 0; i < res.length; i++) { 30 | parseError(res[i]); 31 | } 32 | } catch(e) { 33 | found.push({from: CodeMirror.Pos(e.location.first_line, 0), 34 | to: CodeMirror.Pos(e.location.last_line, e.location.last_column), 35 | severity: 'error', 36 | message: e.message}); 37 | } 38 | return found; 39 | }); 40 | 41 | }); 42 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/lint/css-lint.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | // Depends on csslint.js from https://github.com/stubbornella/csslint 5 | 6 | // declare global: CSSLint 7 | 8 | (function(mod) { 9 | if (typeof exports == "object" && typeof module == "object") // CommonJS 10 | mod(require("../../lib/codemirror")); 11 | else if (typeof define == "function" && define.amd) // AMD 12 | define(["../../lib/codemirror"], mod); 13 | else // Plain browser env 14 | mod(CodeMirror); 15 | })(function(CodeMirror) { 16 | "use strict"; 17 | 18 | CodeMirror.registerHelper("lint", "css", function(text) { 19 | var found = []; 20 | if (!window.CSSLint) return found; 21 | var results = CSSLint.verify(text), messages = results.messages, message = null; 22 | for ( var i = 0; i < messages.length; i++) { 23 | message = messages[i]; 24 | var startLine = message.line -1, endLine = message.line -1, startCol = message.col -1, endCol = message.col; 25 | found.push({ 26 | from: CodeMirror.Pos(startLine, startCol), 27 | to: CodeMirror.Pos(endLine, endCol), 28 | message: message.message, 29 | severity : message.type 30 | }); 31 | } 32 | return found; 33 | }); 34 | 35 | }); 36 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/lint/json-lint.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | // Depends on jsonlint.js from https://github.com/zaach/jsonlint 5 | 6 | // declare global: jsonlint 7 | 8 | (function(mod) { 9 | if (typeof exports == "object" && typeof module == "object") // CommonJS 10 | mod(require("../../lib/codemirror")); 11 | else if (typeof define == "function" && define.amd) // AMD 12 | define(["../../lib/codemirror"], mod); 13 | else // Plain browser env 14 | mod(CodeMirror); 15 | })(function(CodeMirror) { 16 | "use strict"; 17 | 18 | CodeMirror.registerHelper("lint", "json", function(text) { 19 | var found = []; 20 | jsonlint.parseError = function(str, hash) { 21 | var loc = hash.loc; 22 | found.push({from: CodeMirror.Pos(loc.first_line - 1, loc.first_column), 23 | to: CodeMirror.Pos(loc.last_line - 1, loc.last_column), 24 | message: str}); 25 | }; 26 | try { jsonlint.parse(text); } 27 | catch(e) {} 28 | return found; 29 | }); 30 | 31 | }); 32 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/lint/yaml-lint.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | // Depends on js-yaml.js from https://github.com/nodeca/js-yaml 15 | 16 | // declare global: jsyaml 17 | 18 | CodeMirror.registerHelper("lint", "yaml", function(text) { 19 | var found = []; 20 | try { jsyaml.load(text); } 21 | catch(e) { 22 | var loc = e.mark; 23 | found.push({ from: CodeMirror.Pos(loc.line, loc.column), to: CodeMirror.Pos(loc.line, loc.column), message: e.message }); 24 | } 25 | return found; 26 | }); 27 | 28 | }); 29 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/mode/multiplex_test.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function() { 5 | CodeMirror.defineMode("markdown_with_stex", function(){ 6 | var inner = CodeMirror.getMode({}, "stex"); 7 | var outer = CodeMirror.getMode({}, "markdown"); 8 | 9 | var innerOptions = { 10 | open: '$', 11 | close: '$', 12 | mode: inner, 13 | delimStyle: 'delim', 14 | innerStyle: 'inner' 15 | }; 16 | 17 | return CodeMirror.multiplexingMode(outer, innerOptions); 18 | }); 19 | 20 | var mode = CodeMirror.getMode({}, "markdown_with_stex"); 21 | 22 | function MT(name) { 23 | test.mode( 24 | name, 25 | mode, 26 | Array.prototype.slice.call(arguments, 1), 27 | 'multiplexing'); 28 | } 29 | 30 | MT( 31 | "stexInsideMarkdown", 32 | "[strong **Equation:**] [delim $][inner&tag \\pi][delim $]"); 33 | })(); 34 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/runmode/colorize.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror"), require("./runmode")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror", "./runmode"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | var isBlock = /^(p|li|div|h\\d|pre|blockquote|td)$/; 15 | 16 | function textContent(node, out) { 17 | if (node.nodeType == 3) return out.push(node.nodeValue); 18 | for (var ch = node.firstChild; ch; ch = ch.nextSibling) { 19 | textContent(ch, out); 20 | if (isBlock.test(node.nodeType)) out.push("\n"); 21 | } 22 | } 23 | 24 | CodeMirror.colorize = function(collection, defaultMode) { 25 | if (!collection) collection = document.body.getElementsByTagName("pre"); 26 | 27 | for (var i = 0; i < collection.length; ++i) { 28 | var node = collection[i]; 29 | var mode = node.getAttribute("data-lang") || defaultMode; 30 | if (!mode) continue; 31 | 32 | var text = []; 33 | textContent(node, text); 34 | node.innerHTML = ""; 35 | CodeMirror.runMode(text.join(""), mode, node); 36 | 37 | node.className += " cm-s-default"; 38 | } 39 | }; 40 | }); 41 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/scroll/scrollpastend.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | 14 | CodeMirror.defineOption("scrollPastEnd", false, function(cm, val, old) { 15 | if (old && old != CodeMirror.Init) { 16 | cm.off("change", onChange); 17 | cm.off("refresh", updateBottomMargin); 18 | cm.display.lineSpace.parentNode.style.paddingBottom = ""; 19 | cm.state.scrollPastEndPadding = null; 20 | } 21 | if (val) { 22 | cm.on("change", onChange); 23 | cm.on("refresh", updateBottomMargin); 24 | updateBottomMargin(cm); 25 | } 26 | }); 27 | 28 | function onChange(cm, change) { 29 | if (CodeMirror.changeEnd(change).line == cm.lastLine()) 30 | updateBottomMargin(cm); 31 | } 32 | 33 | function updateBottomMargin(cm) { 34 | var padding = ""; 35 | if (cm.lineCount() > 1) { 36 | var totalH = cm.display.scroller.clientHeight - 30, 37 | lastLineH = cm.getLineHandle(cm.lastLine()).height; 38 | padding = (totalH - lastLineH) + "px"; 39 | } 40 | if (cm.state.scrollPastEndPadding != padding) { 41 | cm.state.scrollPastEndPadding = padding; 42 | cm.display.lineSpace.parentNode.style.paddingBottom = padding; 43 | cm.setSize(); 44 | } 45 | } 46 | }); 47 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/tern/tern.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-Tern-completion { 2 | padding-left: 22px; 3 | position: relative; 4 | } 5 | .CodeMirror-Tern-completion:before { 6 | position: absolute; 7 | left: 2px; 8 | bottom: 2px; 9 | border-radius: 50%; 10 | font-size: 12px; 11 | font-weight: bold; 12 | height: 15px; 13 | width: 15px; 14 | line-height: 16px; 15 | text-align: center; 16 | color: white; 17 | -moz-box-sizing: border-box; 18 | box-sizing: border-box; 19 | } 20 | .CodeMirror-Tern-completion-unknown:before { 21 | content: "?"; 22 | background: #4bb; 23 | } 24 | .CodeMirror-Tern-completion-object:before { 25 | content: "O"; 26 | background: #77c; 27 | } 28 | .CodeMirror-Tern-completion-fn:before { 29 | content: "F"; 30 | background: #7c7; 31 | } 32 | .CodeMirror-Tern-completion-array:before { 33 | content: "A"; 34 | background: #c66; 35 | } 36 | .CodeMirror-Tern-completion-number:before { 37 | content: "1"; 38 | background: #999; 39 | } 40 | .CodeMirror-Tern-completion-string:before { 41 | content: "S"; 42 | background: #999; 43 | } 44 | .CodeMirror-Tern-completion-bool:before { 45 | content: "B"; 46 | background: #999; 47 | } 48 | 49 | .CodeMirror-Tern-completion-guess { 50 | color: #999; 51 | } 52 | 53 | .CodeMirror-Tern-tooltip { 54 | border: 1px solid silver; 55 | border-radius: 3px; 56 | color: #444; 57 | padding: 2px 5px; 58 | font-size: 90%; 59 | font-family: monospace; 60 | background-color: white; 61 | white-space: pre-wrap; 62 | 63 | max-width: 40em; 64 | position: absolute; 65 | z-index: 10; 66 | -webkit-box-shadow: 2px 3px 5px rgba(0,0,0,.2); 67 | -moz-box-shadow: 2px 3px 5px rgba(0,0,0,.2); 68 | box-shadow: 2px 3px 5px rgba(0,0,0,.2); 69 | 70 | transition: opacity 1s; 71 | -moz-transition: opacity 1s; 72 | -webkit-transition: opacity 1s; 73 | -o-transition: opacity 1s; 74 | -ms-transition: opacity 1s; 75 | } 76 | 77 | .CodeMirror-Tern-hint-doc { 78 | max-width: 25em; 79 | margin-top: -3px; 80 | } 81 | 82 | .CodeMirror-Tern-fname { color: black; } 83 | .CodeMirror-Tern-farg { color: #70a; } 84 | .CodeMirror-Tern-farg-current { text-decoration: underline; } 85 | .CodeMirror-Tern-type { color: #07c; } 86 | .CodeMirror-Tern-fhint-guess { opacity: .7; } 87 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/addon/tern/worker.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | // declare global: tern, server 5 | 6 | var server; 7 | 8 | this.onmessage = function(e) { 9 | var data = e.data; 10 | switch (data.type) { 11 | case "init": return startServer(data.defs, data.plugins, data.scripts); 12 | case "add": return server.addFile(data.name, data.text); 13 | case "del": return server.delFile(data.name); 14 | case "req": return server.request(data.body, function(err, reqData) { 15 | postMessage({id: data.id, body: reqData, err: err && String(err)}); 16 | }); 17 | case "getFile": 18 | var c = pending[data.id]; 19 | delete pending[data.id]; 20 | return c(data.err, data.text); 21 | default: throw new Error("Unknown message type: " + data.type); 22 | } 23 | }; 24 | 25 | var nextId = 0, pending = {}; 26 | function getFile(file, c) { 27 | postMessage({type: "getFile", name: file, id: ++nextId}); 28 | pending[nextId] = c; 29 | } 30 | 31 | function startServer(defs, plugins, scripts) { 32 | if (scripts) importScripts.apply(null, scripts); 33 | 34 | server = new tern.Server({ 35 | getFile: getFile, 36 | async: true, 37 | defs: defs, 38 | plugins: plugins 39 | }); 40 | } 41 | 42 | var console = { 43 | log: function(v) { postMessage({type: "debug", message: v}); } 44 | }; 45 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/markitup.js: -------------------------------------------------------------------------------- 1 | function mycallback(json, ed) { 2 | var data = $.parseJSON(json); 3 | var modal = UIkit.modal("#upload"); 4 | if (modal.isActive()) { 5 | $('#preview').html(''+data.msg.localfile+''); 6 | } else { 7 | var block = ['!', '[', data.msg.localfile, ']', '(', data.msg.url.replace('!', ''), ')']; 8 | ed.replaceSelection(block.join('')); 9 | } 10 | } 11 | 12 | $(document).ready(function() { 13 | var htmleditor = UIkit.htmleditor($('.markitup'), {markdown:true, mode:'tab', lineNumbers: true}); 14 | 15 | var progressbar = $("#progressbar"), 16 | preview = $("#preview"), 17 | bar = progressbar.find('.uk-progress-bar'), 18 | settings = { 19 | action: '/upload/', // upload url 20 | param: 'filedata', 21 | allow : '*.(jpg|jpeg|gif|png)', // allow only images 22 | 23 | loadstart: function() { 24 | bar.css("width", "0%").text("0%"); 25 | progressbar.removeClass("uk-hidden"); 26 | }, 27 | 28 | progress: function(percent) { 29 | percent = Math.ceil(percent); 30 | bar.css("width", percent+"%").text(percent+"%"); 31 | }, 32 | 33 | allcomplete: function(response) { 34 | bar.css("width", "100%").text("100%"); 35 | setTimeout(function(){ 36 | progressbar.addClass("uk-hidden"); 37 | }, 250); 38 | mycallback(response, htmleditor); 39 | } 40 | }; 41 | var select = UIkit.uploadSelect($("#upload-select"), settings), 42 | drop = UIkit.uploadDrop($("#upload-drop"), settings), 43 | drop2 = UIkit.uploadDrop($(".CodeMirror-code"), settings); 44 | 45 | $("#btn_upload_submit").click(function() { 46 | var preview_img = $('#preview>img'); 47 | var src = preview_img.attr('src'), 48 | text = preview_img.attr('alt'); 49 | if (typeof(src) == "undefined") {src="http://";} 50 | var block = ['!', '[', text, ']', '(', src, ')']; 51 | htmleditor.replaceSelection(block.join('')); 52 | var modal = UIkit.modal("#upload"); 53 | preview.html(''); 54 | modal.hide(); 55 | }) 56 | }); 57 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/mode/xml/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | CodeMirror: XML mode 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 24 | 25 |
26 |

XML mode

27 |
39 | 45 |

The XML mode supports two configuration parameters:

46 |
47 |
htmlMode (boolean)
48 |
This switches the mode to parse HTML instead of XML. This 49 | means attributes do not have to be quoted, and some elements 50 | (such as br) do not require a closing tag.
51 |
alignCDATA (boolean)
52 |
Setting this to true will force the opening tag of CDATA 53 | blocks to not be indented.
54 |
55 | 56 |

MIME types defined: application/xml, text/html.

57 |
58 | -------------------------------------------------------------------------------- /wtxlog/static/admin/cmeditor/mode/xml/test.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: http://codemirror.net/LICENSE 3 | 4 | (function() { 5 | var mode = CodeMirror.getMode({indentUnit: 2}, "xml"), mname = "xml"; 6 | function MT(name) { test.mode(name, mode, Array.prototype.slice.call(arguments, 1), mname); } 7 | 8 | MT("matching", 9 | "[tag&bracket <][tag top][tag&bracket >]", 10 | " text", 11 | " [tag&bracket <][tag inner][tag&bracket />]", 12 | "[tag&bracket ]"); 13 | 14 | MT("nonmatching", 15 | "[tag&bracket <][tag top][tag&bracket >]", 16 | " [tag&bracket <][tag inner][tag&bracket />]", 17 | " [tag&bracket ]"); 18 | 19 | MT("doctype", 20 | "[meta ]", 21 | "[tag&bracket <][tag top][tag&bracket />]"); 22 | 23 | MT("cdata", 24 | "[tag&bracket <][tag top][tag&bracket >]", 25 | " [atom ]", 27 | "[tag&bracket ]"); 28 | 29 | // HTML tests 30 | mode = CodeMirror.getMode({indentUnit: 2}, "text/html"); 31 | 32 | MT("selfclose", 33 | "[tag&bracket <][tag html][tag&bracket >]", 34 | " [tag&bracket <][tag link] [attribute rel]=[string stylesheet] [attribute href]=[string \"/foobar\"][tag&bracket >]", 35 | "[tag&bracket ]"); 36 | 37 | MT("list", 38 | "[tag&bracket <][tag ol][tag&bracket >]", 39 | " [tag&bracket <][tag li][tag&bracket >]one", 40 | " [tag&bracket <][tag li][tag&bracket >]two", 41 | "[tag&bracket ]"); 42 | 43 | MT("valueless", 44 | "[tag&bracket <][tag input] [attribute type]=[string checkbox] [attribute checked][tag&bracket />]"); 45 | 46 | MT("pThenArticle", 47 | "[tag&bracket <][tag p][tag&bracket >]", 48 | " foo", 49 | "[tag&bracket <][tag article][tag&bracket >]bar"); 50 | 51 | })(); 52 | -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/loading.gif -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/.directory: -------------------------------------------------------------------------------- 1 | [Dolphin] 2 | Timestamp=2013,12,15,13,38,10 3 | Version=3 4 | -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/bold.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/bold.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/cancel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/cancel.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/code.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/h1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/h1.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/h2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/h2.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/h3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/h3.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/h4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/h4.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/h5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/h5.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/h6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/h6.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/italic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/italic.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/link.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/link.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/list-bullet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/list-bullet.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/list-numeric.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/list-numeric.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/more.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/more.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/picture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/picture.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/picture_upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/picture_upload.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/preview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/preview.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/sets/markdown/images/quotes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/sets/markdown/images/quotes.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-container.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-container.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-bbcode.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-bbcode.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-dotclear.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-dotclear.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-html.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-html.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-json.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-json.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-markdown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-markdown.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-textile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-textile.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-wiki.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-wiki.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-xml.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor-xml.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/bg-editor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/bg-editor.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/handle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/handle.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/menu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/menu.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/skins/markdown/images/submenu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/markitup/skins/markdown/images/submenu.png -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/templates/preview.css: -------------------------------------------------------------------------------- 1 | /* preview style examples */ 2 | body { 3 | background-color:#EFEFEF; 4 | font:70% Verdana, Arial, Helvetica, sans-serif; 5 | } -------------------------------------------------------------------------------- /wtxlog/static/admin/markitup/templates/preview.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | markItUp! preview template 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /wtxlog/static/admin/select2/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2012 Igor Vaynberg 2 | 3 | Version: @@ver@@ Timestamp: @@timestamp@@ 4 | 5 | This software is licensed under the Apache License, Version 2.0 (the "Apache License") or the GNU 6 | General Public License version 2 (the "GPL License"). You may choose either license to govern your 7 | use of this software only upon the condition that you accept all of the terms of either the Apache 8 | License or the GPL License. 9 | 10 | You may obtain a copy of the Apache License and the GPL License at: 11 | 12 | http://www.apache.org/licenses/LICENSE-2.0 13 | http://www.gnu.org/licenses/gpl-2.0.html 14 | 15 | Unless required by applicable law or agreed to in writing, software distributed under the Apache License 16 | or the GPL Licesnse is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, 17 | either express or implied. See the Apache License and the GPL License for the specific language governing 18 | permissions and limitations under the Apache License and the GPL License. -------------------------------------------------------------------------------- /wtxlog/static/admin/select2/select2-spinner.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/select2/select2-spinner.gif -------------------------------------------------------------------------------- /wtxlog/static/admin/select2/select2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/select2/select2.png -------------------------------------------------------------------------------- /wtxlog/static/admin/select2/select2x2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/select2/select2x2.png -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/css/components/htmleditor.min.css: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | .uk-htmleditor-navbar{background:#eee}.uk-htmleditor-navbar:after,.uk-htmleditor-navbar:before{content:"";display:table}.uk-htmleditor-navbar:after{clear:both}.uk-htmleditor-navbar-nav{margin:0;padding:0;list-style:none;float:left}.uk-htmleditor-navbar-nav>li{float:left}.uk-htmleditor-navbar-nav>li>a{display:block;-moz-box-sizing:border-box;box-sizing:border-box;text-decoration:none;height:40px;padding:0 15px;line-height:40px;color:#444;font-size:11px;cursor:pointer}.uk-htmleditor-navbar-nav>li:hover>a,.uk-htmleditor-navbar-nav>li>a:focus{background-color:#f5f5f5;color:#444;outline:0}.uk-htmleditor-navbar-nav>li>a:active{background-color:#ddd;color:#444}.uk-htmleditor-navbar-nav>li.uk-active>a{background-color:#f5f5f5;color:#444}.uk-htmleditor-navbar-flip{float:right}[data-mode=split] .uk-htmleditor-button-code,[data-mode=split] .uk-htmleditor-button-preview{display:none}.uk-htmleditor-content{border-left:1px solid #ddd;border-right:1px solid #ddd;border-bottom:1px solid #ddd;background:#fff}.uk-htmleditor-content:after,.uk-htmleditor-content:before{content:"";display:table}.uk-htmleditor-content:after{clear:both}.uk-htmleditor-fullscreen{position:fixed;top:0;left:0;right:0;bottom:0;z-index:990}.uk-htmleditor-fullscreen .uk-htmleditor-content{position:absolute;top:40px;left:0;right:0;bottom:0}.uk-htmleditor-fullscreen .uk-icon-expand:before{content:"\f066"}.uk-htmleditor-code,.uk-htmleditor-preview{-moz-box-sizing:border-box;box-sizing:border-box}.uk-htmleditor-preview{padding:20px;overflow-y:scroll;position:relative}[data-mode=tab][data-active-tab=code] .uk-htmleditor-preview,[data-mode=tab][data-active-tab=preview] .uk-htmleditor-code{display:none}[data-mode=split] .uk-htmleditor-code,[data-mode=split] .uk-htmleditor-preview{float:left;width:50%}[data-mode=split] .uk-htmleditor-code{border-right:1px solid #eee}.uk-htmleditor-iframe{position:absolute;top:0;left:0;width:100%;height:100%}.uk-htmleditor .CodeMirror{padding:10px;-moz-box-sizing:border-box;box-sizing:border-box} -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/css/components/upload.css: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | /* ======================================================================== 3 | Component: Upload 4 | ========================================================================== */ 5 | /* 6 | * Create a box-shadow when dragging a file over the upload area 7 | */ 8 | .uk-dragover { 9 | box-shadow: 0 0 20px rgba(100, 100, 100, 0.3); 10 | } 11 | -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/css/components/upload.min.css: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | .uk-dragover{box-shadow:0 0 20px rgba(100,100,100,.3)} -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/uikit/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/uikit/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/uikit/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/admin/uikit/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/alert.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | (function($, UI) { 3 | 4 | "use strict"; 5 | 6 | UI.component('alert', { 7 | 8 | defaults: { 9 | "fade": true, 10 | "duration": 200, 11 | "trigger": ".@-alert-close" 12 | }, 13 | 14 | boot: function() { 15 | 16 | // init code 17 | UI.$html.on("click.alert.uikit", "[data-@-alert]", function(e) { 18 | 19 | var ele = UI.$(this); 20 | 21 | if (!ele.data("alert")) { 22 | 23 | var alert = UI.alert(ele, UI.Utils.options(ele.attr("data-@-alert"))); 24 | 25 | if (UI.$(e.target).is(alert.options.trigger)) { 26 | e.preventDefault(); 27 | alert.close(); 28 | } 29 | } 30 | }); 31 | }, 32 | 33 | init: function() { 34 | 35 | var $this = this; 36 | 37 | this.on("click", this.options.trigger, function(e) { 38 | e.preventDefault(); 39 | $this.close(); 40 | }); 41 | }, 42 | 43 | close: function() { 44 | 45 | var element = this.trigger("close.uk.alert"), 46 | removeElement = function () { 47 | this.trigger("closed.uk.alert").remove(); 48 | }.bind(this); 49 | 50 | if (this.options.fade) { 51 | element.css("overflow", "hidden").css("max-height", element.height()).animate({ 52 | "height" : 0, 53 | "opacity" : 0, 54 | "padding-top" : 0, 55 | "padding-bottom" : 0, 56 | "margin-top" : 0, 57 | "margin-bottom" : 0 58 | }, this.options.duration, removeElement); 59 | } else { 60 | removeElement(); 61 | } 62 | } 63 | 64 | }); 65 | 66 | })(jQuery, UIkit); 67 | -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/alert.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(t,i){"use strict";i.component("alert",{defaults:{fade:!0,duration:200,trigger:".@-alert-close"},boot:function(){i.$html.on("click.alert.uikit","[data-@-alert]",function(t){var e=i.$(this);if(!e.data("alert")){var o=i.alert(e,i.Utils.options(e.attr("data-@-alert")));i.$(t.target).is(o.options.trigger)&&(t.preventDefault(),o.close())}})},init:function(){var t=this;this.on("click",this.options.trigger,function(i){i.preventDefault(),t.close()})},close:function(){var t=this.trigger("close.uk.alert"),i=function(){this.trigger("closed.uk.alert").remove()}.bind(this);this.options.fade?t.css("overflow","hidden").css("max-height",t.height()).animate({height:0,opacity:0,"padding-top":0,"padding-bottom":0,"margin-top":0,"margin-bottom":0},this.options.duration,i):i()}})}(jQuery,UIkit); -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/button.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(t,i){"use strict";i.component("buttonRadio",{defaults:{target:".@-button"},boot:function(){i.$html.on("click.buttonradio.uikit","[data-@-button-radio]",function(t){var n=i.$(this);if(!n.data("buttonRadio")){var o=i.buttonRadio(n,i.Utils.options(n.attr("data-@-button-radio"))),e=i.$(t.target);e.is(o.options.target)&&e.trigger("click")}})},init:function(){var t=this;this.on("click",this.options.target,function(n){var o=i.$(this);o.is('a[href="#"]')&&n.preventDefault(),t.find(t.options.target).not(o).removeClass(i.prefix("@-active")).blur(),t.trigger("change.uk.button",[o.addClass("@-active")])})},getSelected:function(){return this.find(".@-active")}}),i.component("buttonCheckbox",{defaults:{target:".@-button"},boot:function(){i.$html.on("click.buttoncheckbox.uikit","[data-@-button-checkbox]",function(t){var n=i.$(this);if(!n.data("buttonCheckbox")){var o=i.buttonCheckbox(n,i.Utils.options(n.attr("data-@-button-checkbox"))),e=i.$(t.target);e.is(o.options.target)&&n.trigger("change.uk.button",[e.toggleClass("@-active").blur()])}})},init:function(){var n=this;this.on("click",this.options.target,function(o){t(this).is('a[href="#"]')&&o.preventDefault(),n.trigger("change.uk.button",[i.$(this).toggleClass("@-active").blur()])})},getSelected:function(){return this.find(".@-active")}}),i.component("button",{defaults:{},boot:function(){i.$html.on("click.button.uikit","[data-@-button]",function(){var t=i.$(this);if(!t.data("button")){{i.button(t,i.Utils.options(t.attr("data-@-button")))}t.trigger("click")}})},init:function(){var t=this;this.on("click",function(i){t.element.is('a[href="#"]')&&i.preventDefault(),t.toggle(),t.trigger("change.uk.button",[t.element.blur().hasClass("@-active")])})},toggle:function(){this.element.toggleClass("@-active")}})}(jQuery,UIkit); -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/grid.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(t,i){"use strict";var n=[];i.component("gridMatchHeight",{defaults:{target:!1,row:!0},boot:function(){i.ready(function(t){i.$("[data-@-grid-match]",t).each(function(){var t,n=i.$(this);n.data("gridMatchHeight")||(t=i.gridMatchHeight(n,i.Utils.options(n.attr("data-@-grid-match"))))})})},init:function(){var e=this;this.columns=this.element.children(),this.elements=this.options.target?this.find(this.options.target):this.columns,this.columns.length&&(i.$win.on("resize orientationchange",function(){var n=function(){e.match()};return t(function(){n(),i.$win.on("load",n)}),i.Utils.debounce(n,50)}()),i.$html.on("changed.uk.dom",function(){e.columns=e.element.children(),e.elements=e.options.target?e.find(e.options.target):e.columns,e.match()}),this.on("display.uk.check",function(){this.element.is(":visible")&&this.match()}.bind(this)),n.push(this))},match:function(){return i.Utils.matchHeights(this.elements,this.options),this},revert:function(){return this.elements.css("min-height",""),this}}),i.component("gridMargin",{defaults:{cls:"@-grid-margin"},boot:function(){i.ready(function(t){i.$("[data-@-grid-margin]",t).each(function(){var t,n=i.$(this);n.data("gridMargin")||(t=i.gridMargin(n,i.Utils.options(n.attr("data-@-grid-margin"))))})})},init:function(){i.stackMargin(this.element,this.options)}}),i.Utils.matchHeights=function(i,n){i=t(i).css("min-height",""),n=t.extend({row:!0},n);var e=i.filter(":visible:first");if(e.length){var s=Math.ceil(100*parseFloat(e.css("width"))/parseFloat(e.parent().css("width")))>=100?!0:!1,h=function(i){if(!(i.length<2)){var n=0;i.each(function(){n=Math.max(n,t(this).outerHeight())}).each(function(){var i=t(this),e=n-(i.outerHeight()-i.height());i.css("min-height",e+"px")})}};s||(n.row?(e.width(),setTimeout(function(){var n=!1,e=[];i.each(function(){var i=t(this),s=i.offset().top;s!=n&&e.length&&(h(t(e)),e=[],s=i.offset().top),e.push(i),n=s}),e.length&&h(t(e))},0)):h(i))}}}(jQuery,UIkit); -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/nav.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(t,i){"use strict";function n(t){var n=i.$(t),a="auto";if(n.is(":visible"))a=n.outerHeight();else{var s={position:n.css("position"),visibility:n.css("visibility"),display:n.css("display")};a=n.css({position:"absolute",visibility:"hidden",display:"block"}).outerHeight(),n.css(s)}return a}i.component("nav",{defaults:{toggle:">li.@-parent > a[href='#']",lists:">li.@-parent > ul",multiple:!1},boot:function(){i.ready(function(t){i.$("[data-@-nav]",t).each(function(){var t=i.$(this);if(!t.data("nav")){i.nav(t,i.Utils.options(t.attr("data-@-nav")))}})})},init:function(){var t=this;this.on("click",this.options.toggle,function(n){n.preventDefault();var a=i.$(this);t.open(a.parent()[0]==t.element[0]?a:a.parent("li"))}),this.find(this.options.lists).each(function(){var n=i.$(this),a=n.parent(),s=a.hasClass("@-active");n.wrap('
'),a.data("list-container",n.parent()),s&&t.open(a,!0)})},open:function(t,a){var s=this,e=this.element,o=i.$(t);this.options.multiple||e.children(".@-open").not(t).each(function(){var t=i.$(this);t.data("list-container")&&t.data("list-container").stop().animate({height:0},function(){i.$(this).parent().removeClass("@-open")})}),o.toggleClass("@-open"),o.data("list-container")&&(a?(o.data("list-container").stop().height(o.hasClass("@-open")?"auto":0),this.trigger("display.uk.check")):o.data("list-container").stop().animate({height:o.hasClass("@-open")?n(o.data("list-container").find("ul:first")):0},function(){s.trigger("display.uk.check")}))}})}(jQuery,UIkit); -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/smooth-scroll.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | (function($, UI) { 3 | 4 | "use strict"; 5 | 6 | UI.component('smoothScroll', { 7 | 8 | boot: function() { 9 | 10 | // init code 11 | UI.$html.on("click.smooth-scroll.uikit", "[data-@-smooth-scroll]", function(e) { 12 | var ele = UI.$(this); 13 | 14 | if (!ele.data("smoothScroll")) { 15 | var obj = UI.smoothScroll(ele, UI.Utils.options(ele.attr("data-@-smooth-scroll"))); 16 | ele.trigger("click"); 17 | } 18 | 19 | return false; 20 | }); 21 | }, 22 | 23 | init: function() { 24 | 25 | var $this = this; 26 | 27 | this.on("click", function(e) { 28 | e.preventDefault(); 29 | scrollToElement(UI.$(this.hash).length ? UI.$(this.hash) : UI.$("body"), $this.options); 30 | }); 31 | } 32 | }); 33 | 34 | function scrollToElement(ele, options) { 35 | 36 | options = $.extend({ 37 | duration: 1000, 38 | transition: 'easeOutExpo', 39 | offset: 0, 40 | complete: function(){} 41 | }, options); 42 | 43 | // get / set parameters 44 | var target = ele.offset().top - options.offset, 45 | docheight = UI.$doc.height(), 46 | winheight = window.innerHeight; 47 | 48 | if ((target + winheight) > docheight) { 49 | target = docheight - winheight; 50 | } 51 | 52 | // animate to target, fire callback when done 53 | UI.$("html,body").stop().animate({scrollTop: target}, options.duration, options.transition).promise().done(options.complete); 54 | } 55 | 56 | UI.Utils.scrollToElement = scrollToElement; 57 | 58 | if (!$.easing.easeOutExpo) { 59 | $.easing.easeOutExpo = function(x, t, b, c, d) { return (t == d) ? b + c : c * (-Math.pow(2, -10 * t / d) + 1) + b; }; 60 | } 61 | 62 | })(jQuery, UIkit); 63 | -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/smooth-scroll.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(t,o){"use strict";function i(i,n){n=t.extend({duration:1e3,transition:"easeOutExpo",offset:0,complete:function(){}},n);var e=i.offset().top-n.offset,s=o.$doc.height(),l=window.innerHeight;e+l>s&&(e=s-l),o.$("html,body").stop().animate({scrollTop:e},n.duration,n.transition).promise().done(n.complete)}o.component("smoothScroll",{boot:function(){o.$html.on("click.smooth-scroll.uikit","[data-@-smooth-scroll]",function(){var t=o.$(this);if(!t.data("smoothScroll")){{o.smoothScroll(t,o.Utils.options(t.attr("data-@-smooth-scroll")))}t.trigger("click")}return!1})},init:function(){var t=this;this.on("click",function(n){n.preventDefault(),i(o.$(this.hash).length?o.$(this.hash):o.$("body"),t.options)})}}),o.Utils.scrollToElement=i,t.easing.easeOutExpo||(t.easing.easeOutExpo=function(t,o,i,n,e){return o==e?i+n:n*(-Math.pow(2,-10*o/e)+1)+i})}(jQuery,UIkit); -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/toggle.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(t,i,o){"use strict";var s=[];o.component("toggle",{defaults:{target:!1,cls:"@-hidden",animation:!1,duration:200},boot:function(){o.ready(function(t){o.$("[data-@-toggle]",t).each(function(){var t=o.$(this);if(!t.data("toggle")){o.toggle(t,o.Utils.options(t.attr("data-@-toggle")))}}),setTimeout(function(){s.forEach(function(t){t.getToggles()})},0)})},init:function(){var t=this;this.getToggles(),this.on("click",function(i){t.element.is('a[href="#"]')&&i.preventDefault(),t.toggle()}),s.push(this)},toggle:function(){if(this.totoggle.length)if(this.options.animation&&o.support.animation){var t=this,s=o.prefix(this.options.animation).split(",");1==s.length&&(s[1]=s[0]),s[0]=s[0].trim(),s[1]=s[1].trim(),this.totoggle.css("animation-duration",this.options.duration+"ms"),this.totoggle.hasClass(this.options.cls)?(this.totoggle.toggleClass(this.options.cls),this.totoggle.each(function(){o.Utils.animate(this,s[0]).then(function(){i(this).css("animation-duration",""),o.Utils.checkDisplay(this)})})):this.totoggle.each(function(){o.Utils.animate(this,s[1]+" @-animation-reverse").then(function(){o.$(this).toggleClass(t.options.cls).css("animation-duration",""),o.Utils.checkDisplay(this)}.bind(this))})}else this.totoggle.toggleClass(this.options.cls),o.Utils.checkDisplay(this.totoggle)},getToggles:function(){this.totoggle=this.options.target?o.$(this.options.target):[]}})}(this,jQuery,UIkit); -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/touch.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(e){function t(e,t,n,o){return Math.abs(e-t)>=Math.abs(n-o)?e-t>0?"Left":"Right":n-o>0?"Up":"Down"}function n(){p=null,g.last&&(g.el.trigger("longTap"),g={})}function o(){p&&clearTimeout(p),p=null}function i(){a&&clearTimeout(a),l&&clearTimeout(l),u&&clearTimeout(u),p&&clearTimeout(p),a=l=u=p=null,g={}}function r(e){return e.pointerType==e.MSPOINTER_TYPE_TOUCH&&e.isPrimary}if(!e.fn.swipeLeft){var a,l,u,p,c,g={},s=750;e(function(){var y,w,v,f=0,M=0;"MSGesture"in window&&(c=new MSGesture,c.target=document.body),e(document).on("MSGestureEnd gestureend",function(e){var t=e.originalEvent.velocityX>1?"Right":e.originalEvent.velocityX<-1?"Left":e.originalEvent.velocityY>1?"Down":e.originalEvent.velocityY<-1?"Up":null;t&&(g.el.trigger("swipe"),g.el.trigger("swipe"+t))}).on("touchstart MSPointerDown pointerdown",function(t){("MSPointerDown"!=t.type||r(t.originalEvent))&&(v="MSPointerDown"==t.type||"pointerdown"==t.type?t:t.originalEvent.touches[0],y=Date.now(),w=y-(g.last||y),g.el=e("tagName"in v.target?v.target:v.target.parentNode),a&&clearTimeout(a),g.x1=v.pageX,g.y1=v.pageY,w>0&&250>=w&&(g.isDoubleTap=!0),g.last=y,p=setTimeout(n,s),!c||"MSPointerDown"!=t.type&&"pointerdown"!=t.type&&"touchstart"!=t.type||c.addPointer(t.originalEvent.pointerId))}).on("touchmove MSPointerMove pointermove",function(e){("MSPointerMove"!=e.type||r(e.originalEvent))&&(v="MSPointerMove"==e.type||"pointermove"==e.type?e:e.originalEvent.touches[0],o(),g.x2=v.pageX,g.y2=v.pageY,f+=Math.abs(g.x1-g.x2),M+=Math.abs(g.y1-g.y2))}).on("touchend MSPointerUp pointerup",function(n){("MSPointerUp"!=n.type||r(n.originalEvent))&&(o(),g.x2&&Math.abs(g.x1-g.x2)>30||g.y2&&Math.abs(g.y1-g.y2)>30?u=setTimeout(function(){g.el.trigger("swipe"),g.el.trigger("swipe"+t(g.x1,g.x2,g.y1,g.y2)),g={}},0):"last"in g&&(isNaN(f)||30>f&&30>M?l=setTimeout(function(){var t=e.Event("tap");t.cancelTouch=i,g.el.trigger(t),g.isDoubleTap?(g.el.trigger("doubleTap"),g={}):a=setTimeout(function(){a=null,g.el.trigger("singleTap"),g={}},250)},0):g={},f=M=0))}).on("touchcancel MSPointerCancel",i),e(window).on("scroll",i)}),["swipe","swipeLeft","swipeRight","swipeUp","swipeDown","doubleTap","tap","singleTap","longTap"].forEach(function(t){e.fn[t]=function(n){return e(this).on(t,n)}})}}(jQuery); -------------------------------------------------------------------------------- /wtxlog/static/admin/uikit/js/core/utility.min.js: -------------------------------------------------------------------------------- 1 | /*! UIkit 2.16.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ 2 | !function(t,i){"use strict";var n=[];i.component("stackMargin",{defaults:{cls:"@-margin-small-top"},boot:function(){i.ready(function(t){i.$("[data-@-margin]",t).each(function(){var t,n=i.$(this);n.data("stackMargin")||(t=i.stackMargin(n,i.Utils.options(n.attr("data-@-margin"))))})})},init:function(){var s=this;this.columns=this.element.children(),this.columns.length&&(i.$win.on("resize orientationchange",function(){var n=function(){s.process()};return t(function(){n(),i.$win.on("load",n)}),i.Utils.debounce(n,20)}()),i.$html.on("changed.uk.dom",function(){s.columns=s.element.children(),s.process()}),this.on("display.uk.check",function(){s.columns=s.element.children(),this.element.is(":visible")&&this.process()}.bind(this)),n.push(this))},process:function(){return i.Utils.stackMargin(this.columns,this.options),this},revert:function(){return this.columns.removeClass(this.options.cls),this}}),i.ready(function(){var n=[],s=function(){n.forEach(function(t){if(t.is(":visible")){var i=t.parent().width(),n=t.data("width"),s=i/n,e=Math.floor(s*t.data("height"));t.css({height:n>i?e:t.data("height")})}})};return i.$win.on("resize",i.Utils.debounce(s,15)),function(e){i.$("iframe.@-responsive-width",e).each(function(){var i=t(this);!i.data("responsive")&&i.attr("width")&&i.attr("height")&&(i.data("width",i.attr("width")),i.data("height",i.attr("height")),i.data("responsive",!0),n.push(i))}),s()}}()),i.Utils.stackMargin=function(n,s){s=t.extend({cls:"@-margin-small-top"},s),s.cls=i.prefix(s.cls),n=t(n).removeClass(s.cls);var e=!1,a=n.filter(":visible:first"),o=a.length?a.position().top+a.outerHeight()-1:!1;o!==!1&&n.each(function(){var t=i.$(this);t.is(":visible")&&(e?t.addClass(s.cls):t.position().top>=o&&(e=t.addClass(s.cls)))})}}(jQuery,UIkit); -------------------------------------------------------------------------------- /wtxlog/static/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/static/favicon.ico -------------------------------------------------------------------------------- /wtxlog/static/robots.txt: -------------------------------------------------------------------------------- 1 | User-agent: * 2 | Disallow: /admin/ 3 | 4 | -------------------------------------------------------------------------------- /wtxlog/templates/admin/index.html: -------------------------------------------------------------------------------- 1 | {% extends 'admin/master.html' %} 2 | 3 | {% block body %} 4 | {{ super() }} 5 |
6 | 7 |
8 | {% if current_user.is_authenticated() %} 9 |

10 | {{ _('Howdy') }}, {{ current_user.username }} 11 |

12 | {% else %} 13 | {% endif %} 14 |
15 | 16 | {{ _('Back') }} 17 |
18 | {% endblock body %} 19 | -------------------------------------------------------------------------------- /wtxlog/templates/admin/model/a_create.html: -------------------------------------------------------------------------------- 1 | {% extends 'admin/model/create.html' %} 2 | 3 | {% block tail %} 4 | {{ super() }} 5 | 6 | {% include 'admin/model/editor.html' %} 7 | {% endblock %} 8 | -------------------------------------------------------------------------------- /wtxlog/templates/admin/model/a_edit.html: -------------------------------------------------------------------------------- 1 | {% extends 'admin/model/edit.html' %} 2 | 3 | {% block tail %} 4 | {{ super() }} 5 | 6 | {% include 'admin/model/editor.html' %} 7 | {% endblock %} 8 | -------------------------------------------------------------------------------- /wtxlog/templates/admin/my_master.html: -------------------------------------------------------------------------------- 1 | {% extends 'admin/base.html' %} 2 | 3 | {% block access_control %} 4 | {% if current_user.is_authenticated() %} 5 | 14 | {% endif %} 15 | {% endblock %} 16 | -------------------------------------------------------------------------------- /wtxlog/templates/sitemap.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | {% for url in urlset -%}{{ url['loc']|safe }} 4 | {%- if 'lastmod' in url %}{{ url['lastmod'] }}{% endif %} 5 | {%- if 'changefreq' in url %}{{ url['changefreq'] }}{% endif %} 6 | {%- if 'priority' in url %}{{ url['priority'] }}{% endif %} 7 | {% endfor -%} 8 | 9 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/info.json: -------------------------------------------------------------------------------- 1 | { 2 | "application": "wtxlog", 3 | "identifier": "imtx", 4 | "name": "imtx theme", 5 | "author": "digwtx", 6 | "description": "imtx.me theme", 7 | "license": "MIT/X11", 8 | "doctype": "html5" 9 | } 10 | 11 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/css/highlight-default.css: -------------------------------------------------------------------------------- 1 | .hljs{/*display:block;padding:.5em;background:#f0f0f0*/}.hljs,.hljs-subst,.hljs-tag .hljs-title,.lisp .hljs-title,.clojure .hljs-built_in,.nginx .hljs-title{color:black}.hljs-string,.hljs-title,.hljs-constant,.hljs-parent,.hljs-tag .hljs-value,.hljs-rules .hljs-value,.hljs-rules .hljs-value .hljs-number,.hljs-preprocessor,.hljs-pragma,.haml .hljs-symbol,.ruby .hljs-symbol,.ruby .hljs-symbol .hljs-string,.hljs-aggregate,.hljs-template_tag,.django .hljs-variable,.smalltalk .hljs-class,.hljs-addition,.hljs-flow,.hljs-stream,.bash .hljs-variable,.apache .hljs-tag,.apache .hljs-cbracket,.tex .hljs-command,.tex .hljs-special,.erlang_repl .hljs-function_or_atom,.asciidoc .hljs-header,.markdown .hljs-header,.coffeescript .hljs-attribute{color:#800}.smartquote,.hljs-comment,.hljs-annotation,.hljs-template_comment,.diff .hljs-header,.hljs-chunk,.asciidoc .hljs-blockquote,.markdown .hljs-blockquote{color:#888}.hljs-number,.hljs-date,.hljs-regexp,.hljs-literal,.hljs-hexcolor,.smalltalk .hljs-symbol,.smalltalk .hljs-char,.go .hljs-constant,.hljs-change,.lasso .hljs-variable,.makefile .hljs-variable,.asciidoc .hljs-bullet,.markdown .hljs-bullet,.asciidoc .hljs-link_url,.markdown .hljs-link_url{color:#080}.hljs-label,.hljs-javadoc,.ruby .hljs-string,.hljs-decorator,.hljs-filter .hljs-argument,.hljs-localvars,.hljs-array,.hljs-attr_selector,.hljs-important,.hljs-pseudo,.hljs-pi,.haml .hljs-bullet,.hljs-doctype,.hljs-deletion,.hljs-envvar,.hljs-shebang,.apache .hljs-sqbracket,.nginx .hljs-built_in,.tex .hljs-formula,.erlang_repl .hljs-reserved,.hljs-prompt,.asciidoc .hljs-link_label,.markdown .hljs-link_label,.vhdl .hljs-attribute,.clojure .hljs-attribute,.asciidoc .hljs-attribute,.lasso .hljs-attribute,.coffeescript .hljs-property,.hljs-phony{color:#88F}.hljs-keyword,.hljs-id,.hljs-title,.hljs-built_in,.hljs-aggregate,.css .hljs-tag,.hljs-javadoctag,.hljs-phpdoc,.hljs-yardoctag,.smalltalk .hljs-class,.hljs-winutils,.bash .hljs-variable,.apache .hljs-tag,.go .hljs-typename,.tex .hljs-command,.asciidoc .hljs-strong,.markdown .hljs-strong,.hljs-request,.hljs-status{font-weight:bold}.asciidoc .hljs-emphasis,.markdown .hljs-emphasis{font-style:italic}.nginx .hljs-built_in{font-weight:normal}.coffeescript .javascript,.javascript .xml,.lasso .markup,.tex .hljs-formula,.xml .javascript,.xml .vbscript,.xml .css,.xml .hljs-cdata{opacity:.5} -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/css/login.css: -------------------------------------------------------------------------------- 1 | .submit-row input { 2 | background: white url(../images/nav-bg.gif) bottom repeat-x; 3 | padding: 3px 5px; color: black; border: 1px solid #bbb; 4 | border-color: #ddd #aaa #aaa #ddd; cursor:pointer; 5 | } 6 | input[type="text"], input[type="password"] {border: 1px solid #CCCCCC;} 7 | .login form { margin-top: 1em; } 8 | .login .form-row { padding: 4px 0; float: left; width: 100%; } 9 | .login .form-row label { 10 | float: left; width: 9em; padding-right: 0.5em; 11 | line-height: 2em; text-align: right; 12 | font-size: 1em; 13 | color: #333; 14 | } 15 | .login .form-row input {width: 14em; padding:3px;} 16 | .login span.help { font-size: 10px; display: block; } 17 | .login .submit-row { clear: both; padding: 1em 0 0 9.4em; } 18 | .login .password-reset-link { text-align: center; } 19 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/favicon.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/fonts/Droid_Sans.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/fonts/Droid_Sans.woff -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/fonts/Nobile.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/fonts/Nobile.woff -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/arrow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/arrow.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/code.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/databg.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/databg.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/digwtx-qrcode.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/digwtx-qrcode.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/h2_arrow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/h2_arrow.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/headerbg.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/headerbg.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/li-meta.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/li-meta.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/licurrent.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/licurrent.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/loading.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/logo.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/menubg.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/menubg.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/nav-bg.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/nav-bg.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/pattern.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/pattern.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/rss-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/rss-logo.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/search.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/search.gif -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/smallbg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/smallbg.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/top.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/top.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/images/twitter-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/images/twitter-logo.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/js/util.js: -------------------------------------------------------------------------------- 1 | //侧栏跟随 2 | (function(){ 3 | var oDiv=document.getElementById("float"); 4 | if (oDiv==null) return false; 5 | var H=0,iE6; 6 | var Y=oDiv; 7 | if ($(window).width() <= 650) { return; } 8 | while(Y){H+=Y.offsetTop;Y=Y.offsetParent}; 9 | iE6=window.ActiveXObject&&!window.XMLHttpRequest; 10 | if(!iE6){ 11 | window.onscroll=function() 12 | { 13 | var s=document.body.scrollTop||document.documentElement.scrollTop; 14 | if(s>H){oDiv.className="div1 div2";if(iE6){oDiv.style.top=(s-H)+"px";}} 15 | else{oDiv.className="div1";} 16 | }; 17 | } 18 | 19 | })(); 20 | 21 | /* back top */ 22 | $(window).scroll(function () { 23 | var dt = $(document).scrollTop(); 24 | var wt = $(window).height(); 25 | if (dt <= 0) { 26 | $("#top_btn").hide(); 27 | return; 28 | } 29 | $("#top_btn").show(); 30 | if ($.browser.msie && $.browser.version == 6.0) {//IE6返回顶部 31 | $("#top_btn").css("top", wt + dt - 110 + "px"); 32 | } 33 | }); 34 | $("#top_btn").click(function () { $("html,body").animate({ scrollTop: 0 }, 200) }); 35 | 36 | function gethits(id, out) 37 | { 38 | //$('#'+out).html(""); 39 | $.ajax({ 40 | type: "get", 41 | cache:false, 42 | url: '/api/gethits/?id='+id, 43 | timeout: 20000, 44 | error: function(){$('#'+out).html('failed');}, 45 | success: function(t){$('#'+out).html(t);} 46 | }); 47 | } 48 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/mobile/css/style.css: -------------------------------------------------------------------------------- 1 | @charset "utf-8"; 2 | body,ul,ol,form{margin:0 0;padding:0 0} 3 | body{font:16px/1.4 Arial,sans-serif;color:#222;} a{font-size:1.1em;} 4 | ul,ol{list-style:none} 5 | ol li{list-style-type:decimal} 6 | h1{background:#fefeff;font-size:large;border-bottom:2px solid #00aad5} 7 | h2,h3{font-size:medium} h1,h2,h3,div,li,p{margin:0 0;padding:2px 2px;} 8 | h2,li,.t2{border-bottom:1px solid #ccc}.t2{background:#d9f4f4;} 9 | h2.t1{background:#C2EFEF} h2 b{color: #FF6347} 10 | h3{color:#000;} 11 | div{display: block;} div.nav,div.adm{color:#666;margin:1px 2px;} 12 | a:link{color:#369;text-decoration:none}a:visited{color:#669;text-decoration:none} 13 | a:hover{color:#fff;text-decoration:none;background:#00a8d2}a:active{color:#fff;text-decoration:none;background:#f93} 14 | b{color:#ddd;margin: 0 3px;} 15 | .h{background:#fefeff;color:#333;margin:1px 2px;} 16 | .n{border:1px solid #ffed00;background:#fffcaa} 17 | .a,.stamp,#ft,#m h3,#m li{color:#666;font-size:small;margin:2px;} 18 | .t{color:#666;margin:3px;text-align:left;} 19 | .s, .content{word-break:break-all;word-wrap:break-word;} 20 | .content p, .content h2, .content h3 {margin:0.8em 0;} 21 | .content ul, .content ol {margin:0 0 0 2em;} 22 | .content li {list-style-type:square; border:none;} 23 | .content li p {margin:0;} 24 | .content ol li {list-style-type:decimal;} 25 | .content h3 {font-size:1em;} 26 | .content a {font-size:1em;} 27 | .i{width:78%;padding:2px 0;margin:auto;} 28 | .page{margin:5px 2px 3px -4px;} .page a, .page span{margin:0 4px;padding:0 4px;} 29 | .pager_curpage {background:#00a8d2; color:#fff;} 30 | pre,blockquote{background:#F4F4F4;border-left:5px solid #ececec;margin:5px 3px;padding:5px;} 31 | pre{background:#F3F7F7;border-left:5px solid #D9F8F8;} 32 | table{border-collapse:collapse;} 33 | input[type="submit"]{font-size:1.2em;}textarea{height:60%;} 34 | img{max-width:88%;} 35 | .keyword em {font-style:normal; color:#ff0000;} 36 | /*last-modified: 2014-08-17*/ 37 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/static/mobile/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/themes/imtx/static/mobile/favicon.png -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/archives.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | 3 | {% block title %}Monthly Archives: {{ year }}-{{ month }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | 5 | {% block head_extend -%} 6 | 7 | {% endblock %} 8 | 9 | {% block crumb %}Monthly Archives: {{ year }}-{{ month }}{% endblock %} 10 | 11 | {% block main %} 12 | {% include theme('article_lists.html') %} 13 | {% endblock %} 14 | 15 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/article_lists.html: -------------------------------------------------------------------------------- 1 | {% if category %}

Category Archives: {{ category.name }}

{% endif %} 2 | {% if tag %}

Tag Archives: {{ tag.name }}

{% endif %} 3 | {% if topic %}

Topic Archives: {{ topic.name }}

{% endif %} 4 | {% if year or month %}

Monthly Archives: {{ year }}-{{ month }}

{% endif %} 5 | {% if not keyword %}{% set keyword=None %}{% endif %} 6 | 7 | {% if articles %} 8 | {% for article in articles %} 9 |
10 |
    11 |
  • {{ article.created|date('%d') }}
  • 12 |
  • {{ article.created|date('%m') }}月
  • 13 |
14 | 15 |
16 |

{% if article.ontop %}[置顶]{% endif %}{{ article.title|emphasis(keyword)|safe }}

17 |
20 | 21 |
22 |
23 |

{{ article.summary|emphasis(keyword)|safe }}

24 | {% if article.has_more %}

Read More...{% endif %} 25 |

26 |
27 | 28 | {% endfor %} 29 | {% else %} 30 |

没有内容

31 | {% endif %} 32 | 33 | {% if pagination and pagination.page_count > 1 %} 34 | 37 | {% endif %} 38 | 39 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/category.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | 3 | {% block title %}{{ category.seotitle or category.name }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | {% block keywords %}{{ category.seokey }}{% endblock %} 5 | {% block description %}{{ category.seodesc }}{% endblock %} 6 | 7 | {% block head_extend -%} 8 | 9 | 10 | 11 | {%- endblock %} 12 | 13 | {% block crumb %}{{ nav_by_category(category, True) }}{% endblock %} 14 | 15 | {% block main %} 16 | {% include theme('article_lists.html') %} 17 | {% endblock %} 18 | 19 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/errors/403.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | 3 | {% block title %}Forbidden{% endblock %} 4 | 5 | {% block main %} 6 |
7 |

Error 403 - Forbidden

8 |
9 | {% endblock %} 10 | 11 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/errors/404.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | 3 | {% block title %}Oops! Page Not Found{% endblock %} 4 | 5 | {% block main %} 6 |
7 |

Error 404 - Not Found

8 |
9 | {% endblock %} 10 | 11 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/errors/500.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | 3 | {% block title %}Internal Server Error{% endblock %} 4 | 5 | {% block main %} 6 |
7 |

Error 500 - Internal Server Error

8 |
9 | {% endblock %} 10 | 11 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/flatpage.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | {% if flatpage.slug == 'about' %} 3 | {% set active_page = "about" %} 4 | {% endif %} 5 | 6 | {% block title %}{{ flatpage.seotitle or flatpage.title }}{% endblock %} 7 | 8 | {% block head_extend -%} 9 | 10 | 11 | 12 | 13 | {%- endblock %} 14 | 15 | {% block crumb %}{{ flatpage.title }}{% endblock %} 16 | 17 | {% block main %} 18 |
19 |

{{ flatpage.title }}

20 |
21 | {{ flatpage.body_html|safe }} 22 |
23 |
24 | {% endblock %} 25 | 26 | {% block tail -%} 27 | 28 | 29 | {%- endblock %} -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/index.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | 3 | {% block fulltitle %} 4 | {{ label('index_title') or config['SITE_NAME'] }} 5 | {% if pagination %}{% if pagination.page > 1 %}_第{{ pagination.page }}页{% endif %}{% endif %} 6 | {% endblock %} 7 | {% block keywords %}{{ label('index_keywords') }}{% endblock %} 8 | {% block description %}{{ label('index_description') }}{% endblock %} 9 | {% block author %}{{ config['SITE_NAME'] }}{% endblock %} 10 | 11 | {% block head_extend -%} 12 | 13 | 14 | 15 | {%- endblock %} 16 | 17 | {% block crumbwrap %}{% endblock %} 18 | 19 | {% block logo %}

{{ logo() }}

{% endblock %} 20 | 21 | {% block main %} 22 | {% include theme('article_lists.html') %} 23 | {% endblock %} 24 | 25 | {% block friendlinks %} 26 | 27 | {% with flinks = friendlinks() %} 28 | {% if flinks %} 29 |

Links

30 | 35 | {% endif %} 36 | {% endwith %} 37 | {% endblock %} 38 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/archives.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}Monthly Archives: {{ year }}-{{ month }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | 5 | {% block head_extend -%} 6 | 7 | {%- endblock %} 8 | 9 | {% block main %} 10 | {% include theme('mobile/article_lists.html') %} 11 | {% endblock %} 12 | 13 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/article.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}{{ article.seotitle or article.title }}{% endblock %} 4 | 5 | {% block head_extend -%} 6 | 7 | {% if article.get_prev %}{% endif %} 8 | {% if article.get_next %}{% endif %} 9 | {%- endblock %} 10 | 11 | {% block main %} 12 | 13 |

{{ article.title }}

14 |

{{ article.created|date('%Y-%m-%d') }} | {{ article.category.name }}

15 |
16 | {{ article.body_html|safe }} 17 | 18 | {% if article.tags %} 19 |

标签:   {% for tag in article.tags %}{{ tag.name }}{%if not loop.last %}, {% endif %}{% endfor %}.

20 | {% endif %} 21 | {% if article.topic %} 22 |

专题:   {{ article.topic.name }}

23 | {% endif %} 24 | 25 |
26 | 27 |
28 | {% if article.get_prev or article.get_next %} 29 |

相邻文章:

30 | 34 | {% endif %} 35 | 36 | {% with related = get_related_articles(article.id, 15) %} 37 | {% if related %} 38 |

相关文章:

39 |
    40 | {% for article in related %}
  • {{ article.title }} ({{ article.created|date('%Y-%m-%d') }})
  • {% endfor %} 41 |
42 | {% endif %} 43 | {% endwith %} 44 |
45 | 46 | {% endblock %} 47 | 48 | {% block nav %}{{ nav_by_category(article.category) }}»正文{% endblock %} 49 | 50 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/article_lists.html: -------------------------------------------------------------------------------- 1 | {% if category %}

Category Archives: {{ category.name }}

{% endif %} 2 | {% if topic %}

Topic Archives: {{ topic.name }}

{% endif %} 3 | {% if tag %}

Tag Archives: {{ tag.name }}

{% endif %} 4 | {% if year or month %}

Monthly Archives: {{ year }}-{{ month }}

{% endif %} 5 | {% if not keyword %}{% set keyword=None %}{% endif %} 6 | 7 | {% if articles %} 8 | 19 | {% else %} 20 |

没有内容

21 | {% endif %} 22 | 23 | {% if pagination and pagination.page_count > 1 %} 24 |
{{ pagination.pager('$link_first $link_previous ~1~ $link_next $link_last') }}
25 | {% endif %} 26 | 27 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/category.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}{{ category.seotitle or category.name }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | {% block keywords %}{{ category.seokey }}{% endblock %} 5 | {% block description %}{{ category.seodesc }}{% endblock %} 6 | 7 | {% block head_extend -%} 8 | 9 | {%- endblock %} 10 | 11 | {% block main %} 12 | {% include theme('mobile/article_lists.html') %} 13 | {% endblock %} 14 | 15 | {% block nav %}{{ nav_by_category(category) }}{% endblock %} 16 | 17 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/errors/403.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}Forbidden{% endblock %} 4 | 5 | {% block main %} 6 |

Error 403 - Forbidden

7 | {% endblock %} 8 | 9 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/errors/404.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}Oops! Page Not Found{% endblock %} 4 | 5 | {% block main %} 6 |

Error 404 - Not Found

7 | {% endblock %} 8 | 9 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/errors/500.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}Internal Server Error{% endblock %} 4 | 5 | {% block main %} 6 |

Error 500 - Internal Server Error

7 | {% endblock %} 8 | 9 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/flatpage.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}{{ flatpage.seotitle or flatpage.title }}{% endblock %} 4 | 5 | {% block head_extend -%} 6 | 7 | {%- endblock %} 8 | 9 | {% block main %} 10 |

{{ flatpage.title }}

11 |
12 | {{ flatpage.body_html|safe }} 13 |
14 | {% endblock %} 15 | 16 | {% block nav %}»{{ flatpage.title }}{% endblock %} 17 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/index.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block fulltitle %}{{ label('index_title') or config['SITE_NAME'] }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | {% block keywords %}{{ label('index_keywords') }}{% endblock %} 5 | {% block description %}{{ label('index_description') }}{% endblock %} 6 | 7 | {% block head_extend -%} 8 | 9 | {%- endblock %} 10 | 11 | {% block main %} 12 |
13 |
14 | {% include theme('mobile/article_lists.html') %} 15 | {% endblock %} 16 | 17 | 18 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/search.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}搜索: {{ keyword }}{% if pagination and pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | 5 | {% block main %} 6 |

搜索 {{ keyword }} 的结果

7 |
8 |
9 | {% include theme('mobile/article_lists.html') %} 10 | {% endblock %} 11 | 12 | {% block nav %}»搜索{% endblock %} 13 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/tag.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}{{ tag.seotitle or tag.name }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | {% block keywords %}{{ tag.seokey }}{% endblock %} 5 | {% block description %}{{ tag.seodesc }}{% endblock %} 6 | 7 | {% block head_extend -%} 8 | 9 | {%- endblock %} 10 | 11 | {% block main %} 12 | {% include theme('mobile/article_lists.html') %} 13 | {% endblock %} 14 | 15 | {% block nav %} » 标签 » {{ tag.name }}{% endblock %} 16 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/tags.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}标签{% endblock %} 4 | 5 | {% block head_extend -%} 6 | 7 | {%- endblock %} 8 | 9 | {% block main %} 10 |

栏目

11 |
12 | {% with categories = category_lists() %} 13 | {% if categories %} 14 | 19 | {% endif %} 20 | {% endwith %} 21 |
22 | 23 |

标签

24 |
25 | {% with tags = tag_lists() %} 26 | {% if tags %} 27 |
    28 | {%- for tag in tags %} 29 |
  • {{ tag.name }}({{ tag.count }})
  • 30 | {%- endfor %} 31 |
32 | {% endif %} 33 | {% endwith %} 34 |
35 | {% endblock %} 36 | 37 | {% block nav %} » 标签{% endblock %} 38 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/topic.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}{{ topic.seotitle or topic.name }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | {% block keywords %}{{ topic.seokey }}{% endblock %} 5 | {% block description %}{{ topic.seodesc }}{% endblock %} 6 | 7 | {% block head_extend -%} 8 | 9 | {%- endblock %} 10 | 11 | {% block main %} 12 | {% include theme('mobile/article_lists.html') %} 13 | {% endblock %} 14 | 15 | {% block nav %} » 专题 » {{ topic.name }}{% endblock %} 16 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/mobile/topics.html: -------------------------------------------------------------------------------- 1 | {% extends theme('mobile/layout.html') %} 2 | 3 | {% block title %}专题{% endblock %} 4 | 5 | {% block head_extend -%} 6 | 7 | {%- endblock %} 8 | 9 | {% block main %} 10 |

专题

11 |
12 | {% with topics = topic_lists() %} 13 | {% if topics %} 14 | 19 | {% endif %} 20 | {% endwith %} 21 |
22 | {% endblock %} 23 | 24 | {% block nav %} » 专题{% endblock %} 25 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/search.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | 3 | {% block title %}搜索: {{ keyword }}{% if pagination and pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 4 | 5 | {% block crumb %}搜索: {{ keyword }}{% endblock %} 6 | 7 | {% block main %} 8 |

Search Results for {{ keyword }}

9 | {% include theme('article_lists.html') %} 10 | {% endblock %} 11 | 12 | 13 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/tag.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | {% set active_page = "tags" %} 3 | 4 | {% block title %}{{ tag.seotitle or tag.name }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 5 | {% block keywords %}{{ tag.seokey }}{% endblock %} 6 | {% block description %}{{ tag.seodesc }}{% endblock %} 7 | 8 | {% block head_extend -%} 9 | 10 | 11 | 12 | {%- endblock %} 13 | 14 | {% block crumb %}Tags»{{ tag.name }}{% endblock %} 15 | 16 | {% block main %} 17 | {% include theme('article_lists.html') %} 18 | {% endblock %} 19 | 20 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/tags.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | {% set active_page = "tags" %} 3 | 4 | {% block title %}标签{% endblock %} 5 | 6 | {% block head_extend -%} 7 | 8 | 9 | 10 | {%- endblock %} 11 | 12 | {% block crumb %}Tags{% endblock %} 13 | 14 | {% block main %} 15 |
16 |

栏目

17 |
18 | {% with categories = category_lists() %} 19 |
    20 | {% for category in categories -%} 21 |
  • {{ category.name }}{% if not loop.last %}  {% endif %}
  • 22 | {%- endfor %} 23 |
24 | {% endwith %} 25 |
26 | 27 |

标签

28 |
29 | {% with tags = tag_lists() %} 30 |
    31 | {% for tag in tags -%} 32 |
  • {{ tag.name }}({{ tag.count }}){% if not loop.last %}  {% endif %}
  • 33 | {%- endfor %} 34 |
35 | {% endwith %} 36 |
37 |
38 | {% endblock %} 39 | 40 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/topic.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | {% set active_page = "topics" %} 3 | 4 | {% block title %}{{ topic.seotitle or topic.name }}{% if pagination.page>1 %}_第{{ pagination.page }}页{% endif %}{% endblock %} 5 | {% block keywords %}{{ topic.seokey }}{% endblock %} 6 | {% block description %}{{ topic.seodesc }}{% endblock %} 7 | 8 | {% block head_extend -%} 9 | 10 | 11 | 12 | {%- endblock %} 13 | 14 | {% block crumb %}专题»{{ topic.name }}{% endblock %} 15 | 16 | {% block main %} 17 | {% include theme('article_lists.html') %} 18 | {% endblock %} 19 | 20 | -------------------------------------------------------------------------------- /wtxlog/themes/imtx/templates/topics.html: -------------------------------------------------------------------------------- 1 | {% extends theme('layout.html') %} 2 | {% set active_page = "topics" %} 3 | 4 | {% block title %}专题{% endblock %} 5 | 6 | {% block head_extend -%} 7 | 8 | 9 | 10 | {%- endblock %} 11 | 12 | {% block crumb %}专题{% endblock %} 13 | 14 | {% block main %} 15 |
16 |

专题

17 |
18 | {% with topics = topic_lists() %} 19 | 24 | {% endwith %} 25 |
26 |
27 | {% endblock %} 28 | 29 | -------------------------------------------------------------------------------- /wtxlog/translations/zh_Hans_CN/LC_MESSAGES/messages.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/translations/zh_Hans_CN/LC_MESSAGES/messages.mo -------------------------------------------------------------------------------- /wtxlog/utils/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/wtx358/wtxlog/5e0dd09309ff98b26009a9eac48b01afd344cd99/wtxlog/utils/__init__.py -------------------------------------------------------------------------------- /wtxlog/utils/email.py: -------------------------------------------------------------------------------- 1 | from threading import Thread 2 | from flask import current_app 3 | from flask.ext.mail import Message 4 | from ..ext import mail 5 | from .helpers import render_template 6 | 7 | 8 | def send_async_email(app, msg): 9 | with app.app_context(): 10 | mail.send(msg) 11 | 12 | 13 | def send_email(to, subject, template, **kwargs): 14 | app = current_app._get_current_object() 15 | msg = Message('%s %s' % (app.config['APP_MAIL_SUBJECT_PREFIX'], subject), 16 | sender=app.config['APP_MAIL_SENDER'], recipients=[to]) 17 | msg.body = render_template('%s.txt' % template, **kwargs) 18 | msg.html = render_template('%s.html' % template, **kwargs) 19 | thr = Thread(target=send_async_email, args=[app, msg]) 20 | thr.start() 21 | return thr 22 | -------------------------------------------------------------------------------- /wtxlog/utils/filters.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | import re 4 | import markdown 5 | import datetime 6 | 7 | from flask import Markup 8 | from ..ext import keywords_split 9 | 10 | __all__ = ['register_filters', 'markdown_filter'] 11 | 12 | 13 | def markdown_filter(text, codehilite=True): 14 | """ 15 | 代码高亮可选,有的场合不需要高亮,高亮会生成很多代码 16 | 但是fenced_code生成的代码是
~~~包围的
17 |     """
18 |     exts = [
19 |         'abbr', 'attr_list', 'def_list', 'sane_lists', 'fenced_code',
20 |         'tables', 'toc', 'wikilinks', 'joinline',
21 |     ]
22 | 
23 |     if codehilite:
24 |         exts.append('codehilite(guess_lang=True,linenums=False)')
25 | 
26 |     return Markup(markdown.markdown(
27 |         text,
28 |         extensions=exts,
29 |         safe_mode=False,
30 |     ))
31 | 
32 | 
33 | def date_filter(dt, fmt='%Y-%m-%d %H:%M'):
34 |     return dt.strftime(fmt)
35 | 
36 | 
37 | def timestamp_filter(stamp, fmt='%Y-%m-%d %H:%M'):
38 |     return datetime.datetime.fromtimestamp(int(stamp)).strftime(fmt)
39 | 
40 | 
41 | def emphasis(text, keyword=None):
42 |     if keyword is not None:
43 |         for _keyword in keywords_split(keyword):
44 |             _pattern = re.compile(r'(%s)' % _keyword, flags=re.I)
45 |             text = _pattern.sub(r'\1', text)
46 |     return text
47 | 
48 | 
49 | def register_filters(app):
50 |     app.jinja_env.filters['markdown'] = markdown_filter
51 |     app.jinja_env.filters['date'] = date_filter
52 |     app.jinja_env.filters['timestamp'] = timestamp_filter
53 |     app.jinja_env.filters['emphasis'] = emphasis
54 | 


--------------------------------------------------------------------------------
/wtxlog/utils/helpers.py:
--------------------------------------------------------------------------------
 1 | # -*- coding: utf-8 -*-
 2 | 
 3 | import xmlrpclib
 4 | from flask import current_app, request, url_for
 5 | from flask.ext.themes import render_theme_template, get_theme
 6 | from ..models import Category
 7 | 
 8 | 
 9 | def get_current_theme():
10 |     return get_theme(current_app.config.get('THEME', 'default'))
11 | 
12 | 
13 | def render_template(template, **context):
14 |     return render_theme_template(get_current_theme(), template, **context)
15 | 
16 | 
17 | def get_category_ids(longslug=''):
18 |     """"返回指定longslug开头的所有栏目的ID列表"""
19 |     cates = Category.query.filter(Category.longslug.startswith(longslug))
20 |     if cates:
21 |         return [cate.id for cate in cates.all()]
22 |     else:
23 |         return []
24 | 
25 | 
26 | def page_url(page):
27 |     """根据页码返回URL"""
28 |     _kwargs = request.view_args
29 |     if 'page' in _kwargs:
30 |         _kwargs.pop('page')
31 |     if page > 1:
32 |         return url_for(request.endpoint, page=page, **_kwargs)
33 |     return url_for(request.endpoint, **_kwargs)
34 | 
35 | 
36 | def baidu_ping(url):
37 |     """
38 |     :ref: http://zhanzhang.baidu.com/tools/ping
39 | 
40 |     发送给百度Ping服务的XML-RPC客户请求需要包含如下元素:
41 |     RPC端点: http://ping.baidu.com/ping/RPC2
42 |     调用方法名: weblogUpdates.extendedPing
43 |     参数: (应按照如下所列的相同顺序传送)
44 |     博客名称
45 |     博客首页地址
46 |     新发文章地址
47 |     博客rss地址
48 |     """
49 | 
50 |     result = 1
51 |     rpc_server = xmlrpclib.ServerProxy('http://ping.baidu.com/ping/RPC2')
52 | 
53 |     try:
54 |         # 返回0表示提交成功
55 |         current_app.logger.info('begin to ping baidu: <%s>' % url)
56 |         result = rpc_server.weblogUpdates.extendedPing(
57 |             current_app.config.get('SITE_NAME'),
58 |             url_for('main.index', _external=True),
59 |             url,
60 |             url_for('main.feed', _external=True)
61 |         )
62 |     except:
63 |         pass
64 | 
65 |     if result != 0:
66 |         current_app.logger.warning('<%s> ping to baidu failed' % url)
67 | 
68 |     return result == 0
69 | 


--------------------------------------------------------------------------------
/wtxlog/utils/widgets.py:
--------------------------------------------------------------------------------
 1 | # -*- coding: utf-8 -*-
 2 | 
 3 | from wtforms import fields, widgets
 4 | 
 5 | 
 6 | # Define wtforms widget and field
 7 | class MarkitupTextAreaWidget(widgets.TextArea):
 8 |     def __call__(self, field, **kwargs):
 9 |         kwargs.setdefault('class_', 'markitup')
10 |         return super(MarkitupTextAreaWidget, self).__call__(field, **kwargs)
11 | 
12 | 
13 | class MarkitupTextAreaField(fields.TextAreaField):
14 |     widget = MarkitupTextAreaWidget()
15 | 
16 | 
17 | # Define wtforms widget and field
18 | class CKTextAreaWidget(widgets.TextArea):
19 |     def __call__(self, field, **kwargs):
20 |         kwargs.setdefault('class_', 'ckeditor')
21 |         return super(CKTextAreaWidget, self).__call__(field, **kwargs)
22 | 
23 | 
24 | class CKTextAreaField(fields.TextAreaField):
25 |     widget = CKTextAreaWidget()
26 | 


--------------------------------------------------------------------------------