aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2015-04-13 23:38:36 +0200
committerMario Vavti <mario@mariovavti.com>2015-04-13 23:38:36 +0200
commit865b602cf8b4eff5e7da00362df95e52e2fe4f77 (patch)
tree7d6cd6cbc2203d2c84c6bded4e80503327f91ac6
parent05f018e50943fd2f38742b061c7e6f0e4b34995a (diff)
downloadvolse-hubzilla-865b602cf8b4eff5e7da00362df95e52e2fe4f77.tar.gz
volse-hubzilla-865b602cf8b4eff5e7da00362df95e52e2fe4f77.tar.bz2
volse-hubzilla-865b602cf8b4eff5e7da00362df95e52e2fe4f77.zip
webpages appearence
-rw-r--r--mod/webpages.php7
-rw-r--r--view/css/mod_webpages.css42
-rw-r--r--view/pdl/mod_editblock.pdl3
-rw-r--r--view/pdl/mod_editlayout.pdl3
-rw-r--r--view/pdl/mod_editwebpage.pdl3
-rw-r--r--view/theme/redbasic/css/style.css7
-rw-r--r--view/tpl/webpagelist.tpl85
7 files changed, 111 insertions, 39 deletions
diff --git a/mod/webpages.php b/mod/webpages.php
index a9cf61dd1..b4c4e6e4e 100644
--- a/mod/webpages.php
+++ b/mod/webpages.php
@@ -127,7 +127,7 @@ function webpages_content(&$a) {
if($_REQUEST['pagetitle'])
$x['pagetitle'] = $_REQUEST['pagetitle'];
- $o .= status_editor($a,$x);
+ $editor .= status_editor($a,$x);
// Get a list of webpages. We can't display all them because endless scroll makes that unusable,
// so just list titles and an edit link.
@@ -161,14 +161,17 @@ function webpages_content(&$a) {
$o .= replace_macros(get_markup_template('webpagelist.tpl'), array(
'$listtitle' => t('Webpages'),
'$baseurl' => $url,
+ '$create' => t('Create'),
'$edit' => t('Edit'),
+ '$delete' => t('Delete'),
'$pages' => $pages,
'$channel' => $which,
+ '$editor' => $editor,
'$view' => t('View'),
'$preview' => t('Preview'),
'$actions_txt' => t('Actions'),
'$pagelink_txt' => t('Page Link'),
- '$title_txt' => t('Title'),
+ '$title_txt' => t('Page Title'),
'$created_txt' => t('Created'),
'$edited_txt' => t('Edited')
));
diff --git a/view/css/mod_webpages.css b/view/css/mod_webpages.css
index 1b5a798cd..af1ef5357 100644
--- a/view/css/mod_webpages.css
+++ b/view/css/mod_webpages.css
@@ -1,6 +1,40 @@
-.webpage-list-table tr {
- height: 20px;
+#webpage-editor {
+ display: none;
}
-.webpage-list-table td {
- padding: 5px;
+
+#webpage-list-table {
+ width: 100%;
+}
+
+#webpage-list-table th:nth-child(1){
+ white-space: nowrap;
+}
+
+#webpage-list-table td:nth-child(1){
+ padding: 7px 3px 7px 10px;
+ white-space: nowrap;
+}
+#webpage-list-table th:nth-child(5),
+#webpage-list-table td:nth-child(5){
+ padding: 7px 3px;
+ white-space: nowrap;
+}
+
+#webpage-list-table th:nth-child(6),
+#webpage-list-table td:nth-child(6){
+ padding: 7px 10px 7px 7px;
+ white-space: nowrap;
+}
+
+.webpage-list-tool {
+ padding: 7px 10px;
+}
+
+/* this forces collapsed jot to appear expanded */
+.jothidden {
+ display: block !important;
+}
+
+#profile-jot-text {
+ height: 200px;
}
diff --git a/view/pdl/mod_editblock.pdl b/view/pdl/mod_editblock.pdl
new file mode 100644
index 000000000..cef69f194
--- /dev/null
+++ b/view/pdl/mod_editblock.pdl
@@ -0,0 +1,3 @@
+[region=aside]
+[widget=design_tools][/widget]
+[/region] \ No newline at end of file
diff --git a/view/pdl/mod_editlayout.pdl b/view/pdl/mod_editlayout.pdl
new file mode 100644
index 000000000..cef69f194
--- /dev/null
+++ b/view/pdl/mod_editlayout.pdl
@@ -0,0 +1,3 @@
+[region=aside]
+[widget=design_tools][/widget]
+[/region] \ No newline at end of file
diff --git a/view/pdl/mod_editwebpage.pdl b/view/pdl/mod_editwebpage.pdl
new file mode 100644
index 000000000..cef69f194
--- /dev/null
+++ b/view/pdl/mod_editwebpage.pdl
@@ -0,0 +1,3 @@
+[region=aside]
+[widget=design_tools][/widget]
+[/region] \ No newline at end of file
diff --git a/view/theme/redbasic/css/style.css b/view/theme/redbasic/css/style.css
index e1b1b1e91..b03cdd4dc 100644
--- a/view/theme/redbasic/css/style.css
+++ b/view/theme/redbasic/css/style.css
@@ -1922,10 +1922,15 @@ nav .dropdown-menu {
}
[id^="cloud-index-"]:hover td,
-.cloud-index-active {
+.cloud-index-active, {
background-color: $item_colour;
}
+[id^="webpage-list-item"]:hover td {
+ background-color: $item_colour;
+}
+
+
nav ul li .undefined,
nav ul li .notify-seen,
nav ul li .notify-unseen
diff --git a/view/tpl/webpagelist.tpl b/view/tpl/webpagelist.tpl
index 4e1bc3d57..4e5b3e0e4 100644
--- a/view/tpl/webpagelist.tpl
+++ b/view/tpl/webpagelist.tpl
@@ -1,36 +1,57 @@
-{{$listtitle}}
+<div class="section-title-wrapper">
+ {{if $editor}}
+ <div class="pull-right">
+ <button id="webpage-create-btn" class="btn btn-xs btn-success" onclick="openClose('webpage-editor');"><i class="icon-edit"></i>&nbsp;{{$create}}</button>
+ </div>
+ {{/if}}
+ <h2>{{$listtitle}}</h2>
+ <div class="clear"></div>
+</div>
+{{if $editor}}
+<div id="webpage-editor" class="section-content-tools-wrapper form-group">
+ {{$editor}}
+</div>
+{{/if}}
{{if $pages}}
-
- <div id="pagelist-content-wrapper" class="generic-content-wrapper-styled">
- <table class="webpage-list-table">
- <tr><td>{{$actions_txt}}</td><td>{{$pagelink_txt}}</td><td>{{$title_txt}}</td><td>{{$created_txt}}</td><td>{{$edited_txt}}</td></tr>
+<div id="pagelist-content-wrapper" class="generic-content-wrapper-styled">
+ <table id="webpage-list-table">
+ <tr>
+ <th width="1%">{{$pagelink_txt}}</th>
+ <th width="95%">{{$title_txt}}</th>
+ <th width="1%"></th>
+ <th width="1%"></th>
+ <th width="1%" class="hidden-xs">{{$created_txt}}</th>
+ <th width="1%" class="hidden-xs">{{$edited_txt}}</th>
+ </tr>
{{foreach $pages as $key => $items}}
- {{foreach $items as $item}}
- <tr>
- <td>
- {{if $edit}}<a href="{{$baseurl}}/{{$item.url}}" title="{{$edit}}" class="btn btn-default"><i class="icon-pencil"></i></a> {{/if}}
- </td>
- <td>
- {{if $view}}<a href="page/{{$channel}}/{{$item.pagetitle}}" title="{{$view}}">{{$item.pagetitle}}</a>
- {{else}}{{$item.pagetitle}}
- {{/if}}
- </td>
- <td>
- {{$item.title}}
- </td>
- <td>
- {{$item.created}}
- </td>
- <td>
- {{$item.edited}}
- </td>
- </tr>
- {{/foreach}}
+ {{foreach $items as $item}}
+ <tr id="webpage-list-item-{{$item.url}}">
+ <td>
+ {{if $view}}
+ <a href="page/{{$channel}}/{{$item.pagetitle}}" title="{{$view}}">{{$item.pagetitle}}</a>
+ {{else}}
+ {{$item.pagetitle}}
+ {{/if}}
+ </td>
+ <td>
+ {{$item.title}}
+ </td>
+ <td class="webpage-list-tool">
+ {{if $edit}}<a href="{{$baseurl}}/{{$item.url}}" title="{{$edit}}"><i class="icon-pencil"></i></a>{{/if}}
+ </td>
+ <td class="webpage-list-tool">
+ {{if $edit}}<a href="#" title="{{$delete}}" onclick="dropItem('item/drop/{{$item.url}}', '#webpage-list-item-{{$item.url}}'); return false;"><i class="icon-trash drop-icons"></i></a>{{/if}}
+ </td>
+ <td class="hidden-xs">
+ {{$item.created}}
+ </td>
+ <td class="hidden-xs">
+ {{$item.edited}}
+ </td>
+ </tr>
+ {{/foreach}}
{{/foreach}}
-
- </table>
- </div>
-
- <div class="clear"></div>
-
+ </table>
+</div>
+<div class="clear"></div>
{{/if}}