No edit summary
(Imported by PageSync)
 
Line 9: Line 9:
</noinclude><includeonly><!--
</noinclude><includeonly><!--


-->{{#vardefine:@allow sidebar edit |{{#ifingroup:user |{{#if:{{#urlget:veaction}}{{#urlget:action}}||yes}} }} }}<!--
-->{{Csp default sidebar
 
|$pageData={{{$pageData|}}}
--><div class="tab-content"><!--
|$classData={{{$classData|}}}
-->{{#tag:_input||type=radio|id=sidebar-view|name=toggle-sidebar|checked=checked|class=d-none sidebar-view}}<!--
--><div class="card sidebar-view-tab">
<div class="card-header">{{#ifeq:{{#var:@allow sidebar edit}} |yes |<span style="float:right">{{#tag:wslabel|Edit|for=sidebar-edit|class=btn btn-secondary}}</span>}}
<b class="d-block">{{#caprint:$base[Base properties][Class]}}</b>
{{#caprint:$base[Base properties][Title]}}
</div><!-- end of .card-header -->
<div class="card-body">
{{Sidebar item
|Value={{#caprint:$class[Page properties][Short description]}}
|Cols=0-12
}}
}}
{{Sidebar item
{{Show SEO in sidebar}}<!--
|Label=Views
|Value={{#wsstats:id={{PAGEID}}}}
}}
</div><!-- end of .card-body -->
</div><!-- end of .card
 
-->{{#ifeq:{{#var:@allow sidebar edit}} |yes |<!--
-->{{#tag:wsfield||type=radio|id=sidebar-edit|name=toggle-sidebar|class=d-none sidebar-edit}}<!--
--><div class="card sidebar-edit-tab"><!--
--><wsform action="addToWiki"><!--
 
// wsedits for base properties
-->{{#tag:wsedit ||target={{PAGEID}} |template=Base properties |formfield=Title |mwslot=ws-base-props}}<!--
 
// wscreate or wsedits for page properties
// use casize to check if the slot already exists. Then wsedit, else wscreate.
-->{{#if:{{#casize:$class}}
|{{#tag:wsedit ||target={{PAGEID}} |template=Page properties |formfield=Short description |mwslot=ws-class-props}}
|<wscreate mwwrite="{{FULLPAGENAME}}" mwtemplate="Page properties" mwslot="ws-class-props" mwfields="Short description" />
}}<!-- end of #if  -->
 
<div class="card-header"><span style="float:right">{{#tag:wslabel|Close|for=sidebar-view|class=btn btn-secondary}}</span>
<b class="d-block">{{#caprint:$base[Base properties][Class]}}</b>
{{#caprint:$base[Base properties][Title]}}
</div><!-- end of .card-header -->
<div class="card-body">
{{Sidebar item
|Label=Title
|Value={{#tag:wsfield ||type=text |name=Title |required=required |class=form-control |value={{#caprint:$base[Base properties][Title]}} }}
}}
{{Sidebar item
|Label=Short description
|Value={{#tag:wsfield ||type=textarea |name=Short description |class=form-control |value={{#caprint:$class[Page properties][Short description]}} }}
}}
 
<div class="text-right">
{{#tag:wslabel|Close|for=sidebar-view|class=btn btn-secondary mb-0}}
<wsfield type="submit" value="Save" class="btn btn-primary" />
</div>
</div><!-- end of .card-body -->
</wsform>
</div><!-- end of .card -->
|}}<!-- end of #ifeq @allow sidebar edit == yes -->
</div><!-- end of .tab-content
 
-->{{Show SEO in sidebar}}<!--


--></includeonly>
--></includeonly>

Latest revision as of 09:33, 15 July 2025


This is the Page sidebar template. It should be called in the following format:

{{Page sidebar}}