summaryrefslogtreecommitdiff
path: root/lib/tpl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tpl')
-rw-r--r--lib/tpl/default/media.css115
-rw-r--r--lib/tpl/default/media.php54
-rw-r--r--lib/tpl/default/mediaedit.php87
-rw-r--r--lib/tpl/default/mediamanager.php (renamed from lib/tpl/default/mediaref.php)29
-rw-r--r--lib/tpl/default/style.ini3
5 files changed, 128 insertions, 160 deletions
diff --git a/lib/tpl/default/media.css b/lib/tpl/default/media.css
new file mode 100644
index 000000000..96aac41ce
--- /dev/null
+++ b/lib/tpl/default/media.css
@@ -0,0 +1,115 @@
+/**
+ * The CSS in here cotrols the appearance of the media manager
+ */
+
+#media__left {
+ width: 30%;
+ float: left;
+ border-right: solid 1px __dark__;
+}
+
+#media__right {
+ width: 68%;
+ float: left;
+ border-left: solid 1px __dark__;
+ margin-left: -1px;
+}
+
+#media__tree img {
+ float:left;
+ padding: 0.5em 0.3em 0 0;
+}
+
+#media__tree ul {
+ list-style-type: none;
+ list-style-image: none;
+}
+
+#media__tree li {
+ clear: left;
+ list-style-type: none;
+ list-style-image: none;
+}
+
+/* --- file list --- */
+
+#media__content img.load {
+ margin: 1em auto;
+}
+
+#media__content #scroll__here {
+ border: 1px dashed __dark__;
+}
+
+#media__content .odd {
+ background-color: __lighter__;
+ padding: 0.4em;
+}
+
+#media__content .even {
+ padding: 0.4em;
+}
+
+#media__content a.mediafile {
+ margin-right: 1.5em;
+ font-weight: bold;
+}
+
+#media__content div.detail {
+ padding: 0.3em 0 0.3em 2em;
+}
+
+#media__content div.detail div.thumb {
+ float: left;
+ width: 130px;
+ text-align: center;
+ margin-right: 0.4em;
+}
+
+
+#media__content img.btn {
+ vertical-align: text-bottom;
+}
+
+/* --- upload form --- */
+
+#media__content form.upload {
+ display: block;
+ border-bottom: solid 1px __dark__;
+ padding: 0 0 1em 2em;
+}
+
+/* --- meta edit form --- */
+
+#media__content form.meta {
+ display: block;
+ padding: 0 0 1em 0;
+}
+
+#media__content form.meta label {
+ display: block;
+ width: 20%;
+ float: left;
+ text-align: right;
+ font-weight: bold;
+ padding-right: 1em;
+}
+
+#media__content form.meta .edit {
+ float: left;
+ width: 75%;
+}
+
+#media__content form.meta textarea.edit {
+ height: 6em;
+}
+
+#media__content form.meta div.metafield {
+ clear: left;
+}
+
+#media__content form.meta div.buttons {
+ clear: left;
+ margin-left: 20%;
+ padding-left: 1em;
+}
diff --git a/lib/tpl/default/media.php b/lib/tpl/default/media.php
deleted file mode 100644
index c2c632e46..000000000
--- a/lib/tpl/default/media.php
+++ /dev/null
@@ -1,54 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<?php
-/**
- * DokuWiki Default Template
- *
- * This is the template for the media selection popup.
- *
- * You should leave the doctype at the very top - It should
- * always be the very first line of a document.
- *
- * @link http://wiki.splitbrain.org/wiki:tpl:templates
- * @author Andreas Gohr <andi@splitbrain.org>
- */
-?>
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $conf['lang']?>" lang="<?php echo $conf['lang']?>" dir="ltr">
-<head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title><?php echo hsc($lang['mediaselect'])?> [<?php echo hsc($conf['title'])?>]</title>
-
- <?php tpl_metaheaders()?>
-
- <link rel="shortcut icon" href="<?php echo DOKU_TPL?>images/favicon.ico" />
-
-</head>
-
-<body>
-<div class="dokuwiki">
- <?php html_msgarea()?>
-
- <h1><?php echo hsc($lang['mediaselect'])?> <code><?php echo hsc($NS)?></code></h1>
-
- <div class="mediaselect">
-
- <div class="mediaselect-left">
- <strong><a href="<?php echo DOKU_BASE?>lib/exe/media.php?ns="><?php echo hsc($lang['namespaces'])?></a></strong>
-
- <?php tpl_medianamespaces()?>
- </div>
-
- <div class="mediaselect-right">
- <?php tpl_mediafilelist()?>
-
- <div class="uploadform">
- <?php tpl_mediauploadform()?>
- </div>
- </div>
-
- </div>
-
-</div>
-</body>
-</html>
-
diff --git a/lib/tpl/default/mediaedit.php b/lib/tpl/default/mediaedit.php
deleted file mode 100644
index 79175e009..000000000
--- a/lib/tpl/default/mediaedit.php
+++ /dev/null
@@ -1,87 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<?php
-/**
- * DokuWiki Default Template
- *
- * This is the template for editing image meta data.
- * It is displayed in the media popup.
- *
- * You should leave the doctype at the very top - It should
- * always be the very first line of a document.
- *
- * @link http://wiki.splitbrain.org/wiki:tpl:templates
- * @author Andreas Gohr <andi@splitbrain.org>
- */
-?>
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $conf['lang']?>" lang="<?php echo $conf['lang']?>" dir="ltr">
-<head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title><?php echo hsc($lang['mediaselect'])?> [<?php echo hsc($conf['title'])?>]</title>
-
- <?php tpl_metaheaders()?>
-
- <link rel="shortcut icon" href="<?php echo DOKU_TPL?>images/favicon.ico" />
-</head>
-
-<body>
-<div class="dokuwiki">
- <?php html_msgarea()?>
-
- <h1><?php echo hsc($lang['metaedit'])?> <code><?php echo hsc(noNS($IMG))?></code></h1>
-
- <div class="mediaedit">
- <?php/* everything in meta array is tried to save and read */?>
-
- <div class="data">
- <form action="<?php echo DOKU_BASE?>lib/exe/media.php" accept-charset="utf-8" method="post">
- <input type="hidden" name="edit" value="<?php echo hsc($IMG)?>" />
- <input type="hidden" name="save" value="1" />
-
- <label class="block" for="img__title"><?php echo $lang['img_title']?></label>
- <input type="text" name="meta[Iptc.Headline]" id="img__title" class="edit"
- value="<?php echo hsc(tpl_img_getTag('IPTC.Headline'))?>" /><br />
-
- <label class="block" for="img__caption"><?php echo $lang['img_caption']?></label>
- <textarea name="meta[Iptc.Caption]" id="img__caption" class="edit" rows="5"><?php
- echo hsc(tpl_img_getTag(array('IPTC.Caption',
- 'EXIF.UserComment',
- 'EXIF.TIFFImageDescription',
- 'EXIF.TIFFUserComment')));
- ?></textarea><br />
-
- <label class="block" for="img__artist"><?php echo $lang['img_artist']?></label>
- <input type="text" name="meta[Iptc.Byline]" id="img__artist" class="edit"
- value="<?php echo hsc(tpl_img_getTag(array('Iptc.Byline',
- 'Exif.TIFFArtist',
- 'Exif.Artist',
- 'Iptc.Credit')))?>" /><br />
-
- <label class="block" for="img__copy"><?php echo $lang['img_copyr']?></label>
- <input type="text" name="meta[Iptc.CopyrightNotice]" id="img__copy" class="edit"
- value="<?php echo hsc(tpl_img_getTag(array('Iptc.CopyrightNotice','Exif.TIFFCopyright','Exif.Copyright')))?>" /><br />
-
-
- <label class="block" for="img__keywords"><?php echo $lang['img_keywords']?></label>
- <textarea name="meta[Iptc.Keywords]" id="img__keywords" class="edit"><?php
- echo hsc(tpl_img_getTag(array('IPTC.Keywords',
- 'EXIF.Category')));
- ?></textarea><br />
-
-
- <input type="submit" value="<?php echo $lang['btn_save']?>" title="ALT+S"
- accesskey="s" class="button" />
-
- </form>
- </div>
-
-
- <div class="footer">
- <hr />
- <?php tpl_button('backtomedia')?>
- </div>
- </div>
-
-</div>
-</body>
-</html>
diff --git a/lib/tpl/default/mediaref.php b/lib/tpl/default/mediamanager.php
index 06af5764c..10b31ba63 100644
--- a/lib/tpl/default/mediaref.php
+++ b/lib/tpl/default/mediamanager.php
@@ -4,8 +4,7 @@
/**
* DokuWiki Default Template
*
- * This is the template for displaying references to a media file.
- * It is displayed in the media popup.
+ * This is the template for the media manager popup
*
* You should leave the doctype at the very top - It should
* always be the very first line of a document.
@@ -18,33 +17,25 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php echo hsc($lang['mediaselect'])?> [<?php echo hsc($conf['title'])?>]</title>
-
<?php tpl_metaheaders()?>
-
<link rel="shortcut icon" href="<?php echo DOKU_TPL?>images/favicon.ico" />
-
</head>
<body>
-<div class="dokuwiki">
- <?php html_msgarea()?>
+<div id="media__manager" class="dokuwiki">
+ <?html_msgarea()?>
+ <div id="media__left">
+ <h1><?php echo hsc($lang['mediaselect'])?></h1>
- <h1><?php echo hsc($lang['reference'])?> <code><?php echo hsc(noNS($DEL))?></code></h1>
+ <?php tpl_mediaTree() ?>
- <div class="mediaref">
- <div class="mediaref_head">
- <p><?php echo hsc($lang['ref_inuse'])?></p>
+ <?php /* keep the id! additional elements are inserted via JS here */?>
+ <div id="media__opts"></div>
</div>
- <?php tpl_showreferences($mediareferences)?>
-
- <div class="mediaref_footer">
- <hr />
- <?php tpl_button('backtomedia')?>
+ <div id="media__right">
+ <?php tpl_mediaContent() ?>
</div>
- </div>
-
</div>
</body>
</html>
-
diff --git a/lib/tpl/default/style.ini b/lib/tpl/default/style.ini
index e6452ad90..bb4cd2305 100644
--- a/lib/tpl/default/style.ini
+++ b/lib/tpl/default/style.ini
@@ -9,6 +9,9 @@
layout.css = screen
design.css = screen
style.css = screen
+
+media.css = screen
+
rtl.css = rtl
print.css = print