pre: import.fps

This commit is contained in:
undefined committed 2020-09-01 22:40:52 +08:00
1 parent ce69235207
commit a2bd6fc652
2 files changed
+39 -3

No files matched your search

+3 -3
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/fps-importer",
"version": "1.0.0",
"version": "1.0.2",
"description": "Import FPS problems",
"main": "package.json",
"repository": "https://github.com/hydro-dev/Hydro.git",
@@ -9,11 +9,11 @@
"dependencies": {
"adm-zip": "^0.4.16",
"fs-extra": "^9.0.1",
"hydrooj": "^2.12.22",
"turndown": "^6.0.0",
"xml2js": "^0.4.23"
},
"devDependencies": {
"hydrooj": "^2.12.22",
"@types/turndown": "^5.0.0",
"@types/xml2js": "^0.4.5"
},
@@ -21,4 +21,4 @@
"build": "tsc",
"lint": "eslint . --ext ts --fix"
}
}
}
@@ -0,0 +1,36 @@
{% extends "layout/basic.html" %}
{% block content %}
<div class="row">
<div class="medium-9 columns">
<div class="section">
<div class="section__body">
<form method="post">
<div class="row"><div class="columns">
<label>
{{ _('FPS FILE') }}
<textarea name="content" class="textbox" data-xml style="height: 500px"></textarea>
</label>
</div></div>
<div class="row"><div class="columns">
<input type="hidden" name="csrfToken" value="{{ handler.csrfToken }}">
<button type="submit" class="rounded primary button">
{{ _('Import') }}
</button>
<button type="button" class="rounded button" onclick="window.history.go(-1)">
{{ _('Cancel') }}
</button>
</div></div>
</form>
</div>
</div>
</div>
<div class="medium-3 columns">
<div class="section side">
<div class="section__body typo">
<h2>{{ _('What is this?') }}</h2>
<p>{{ _('With this feature, you can import problems that you can view from a site to here. Their title, content, tags and categories will be imported.') }}</p>
</div>
</div>
</div>
</div>
{% endblock %}