الگو:Sidebar/توضیحات

نسخهٔ تاریخ ‏۱۶ مهٔ ۲۰۲۱، ساعت ۰۷:۱۶ توسط admin>Nazarzadeh (۱ نسخه واردشده)
(تفاوت) → نسخهٔ قدیمی‌تر | نمایش نسخهٔ فعلی (تفاوت) | نسخهٔ جدیدتر ← (تفاوت)

الگو:زیرصفحه توضیحات الگو:لوآ خطای لوآ: خطای داخلی: مفسر با وضعیت 1 خارج شده است. خطای لوآ: خطای داخلی: مفسر با وضعیت 1 خارج شده است.

این الگوی متا برای ساخت نوار الگوی کناری استفاده می‌گردد. مانند الگوهای ناوبری عمودی.


استفاده

الگوی عمومی و ساده بدون پارامترهای پیچیده:

{{نوار جانبی
| name = {{subst:PAGENAME}}
| pretitle = 
| title = 
| image = 
| headingstyle = 
| contentstyle = 

| above = 

| heading1 = 
| content1 = 

| heading2 = 
| content2 = 

| heading3 = 
| content3 = 

<!-- این روند را برای پارامتر بیشتر میتوانید ادامه دهید: -->

| heading35 = 
| content35 = 

| below = 

}}

پارامترها

هیچ‌کدام از پارامترها اجباری نیستند, و در صورت دیدن الگوی{{navbar}} ن · ب · و در انتهای الگو می‌توانید الگو را نمایش یا ویرایش ویا در بحث مربوط شرکت نمایید.

پارامترهای اصلی

پارامتر توضیح
الگو:پارا نام نوار کناری(جانبی) که در جلوی "Template:" در ابتدای متن الگو قرار می‌گیرد.
الگو:پارا نامی که در ابتدای نوار دیده خواهدشد.
الگو:پارا برای گذاردن نگاره(تصویر) دربالای نوار کناری الگو:پارا (درصورت لزوم). از سینتاکس ویکی استفاده کنید (مانند [[File:...]]).
برای افزودن توضیح به نگاره از الگو:پارا استفاده کنید.
الگو:پارا Use to place a line such as "Part of the X series on" before the title.
الگو:پارا Use to place a title for the sidebar at the top of the sidebar. (If الگو:پارا is used, it will appear immediately below it).
الگو:پارا Use to place an image between the الگو:پارا (if used) and first section. As with الگو:پارا, full wiki syntax is expected (i.e. [[File:...]]).
To add a caption below the image, use الگو:پارا.
الگو:پارا Use to alter the default CSS styling set for section headings.
To alter the CSS styling for a specific section's heading, use الگو:پارا, where n is the number of the section.
الگو:پارا Use to alter the default CSS styling set for section content.
To alter the CSS styling for a particular section's content, use الگو:پارا, where n is the number of the section.
الگو:پارا
الگو:پارا
First section's heading / content. content1 is required if heading1 is also to appear.
الگو:پارا
الگو:پارا
Second section's heading / content. (content2 required if heading2 also to appear; etc.)
الگو:پارا
الگو:پارا
Third section's heading / content.
...... etc ......
الگو:پارا
الگو:پارا
Currently, the last possible section heading and/or content.

دیگر پارامترها

پارامتر توضیح
الگو:پارا مانند الگو:پارا offered by {{Navbox}}.

Microformat classes for the corresponding parameters.
(الگو:پارا and الگو:پارا are applied across the whole sidebar.)

الگو:پارا Same as the الگو:پارا offered by {{Navbox}}.
(Use, for example, to add one or more portal links to the bottom of the template (shown, by default, in bold).)

Use to alter the default CSS styling for the corresponding parameters.
(الگو:پارا and الگو:پارا are applied across the whole sidebar.)

الگو:پارا
الگو:پارا
Use to amend the default cellspacing / cellpadding set for the infobox-class table with which the sidebar is built.
Set to "off", "none", etc (without quotes) to remove the {{navbar}} links (·· E) that otherwise appear at the bottom of the sidebar.
Use to specify the font style used by the navbar at the bottom of the sidebar (see {{navbar}} for options available).

Handling long links

{{Normalwraplink}} may be used to handle links that should wrap within the sidebar or otherwise need to be made to wrap, in order to prevent the sidebar from becoming too wide. Use {{normalwraplink|longlinkname}}, where الگو:پارا is the long link without its square brackets.

Use the الگو:پارا parameter to turn link wrapping off for the whole template.

کدهای جاسازی

الگوهای نوارکناری را می‌توانید با استفاده‌از الگو:پارا در یک الگوی نوار کناری جای دهید. برای ایجاد یک ماژول نوار کناری, یا برای ساخت بخشهای منطقی بیشتر.

الگو:نوار جانبی

{{نوار جانبی
| title = Top-level title
| content1 =
 {{نوار جانبی|child=yes
  | title = First subsection
  | heading1 = Heading 1.1
  | content1 = Content 1.1
 }}
| content2 =
 {{نوار جانبی|child=yes
  | title = Second subsection
  | heading1 = Heading 2.1
  | content1 = Content 2.1
 }}
| below = "below" text
}}

Note in the examples above that the child sidebar is placed in a content field, not a heading field. Notice also that the section subheadings do not appear in bold if this is not explicitly specified. To obtain bold section headings, place the child sidebar in a heading field, using either:

الگو:نوار جانبی

{{نوار جانبی
| title = Top-level title
| heading1 =
 {{نوار جانبی|child=yes
  | title = First subsection
  | heading1 = Heading 1.1
  | content1 = Content 1.1
 }}
| heading2 =
 {{نوار جانبی|child=yes
  | title = Second subsection
  | heading1 = Heading 2.1
  | content1 = Content 2.1
 }}
| below = "below" text
}}

or:

الگو:نوار جانبی

{{نوار جانبی
| title = Top-level title
| heading1 = First subsection
 {{نوار جانبی|child=yes
  | heading1 = Heading 1.1
  | content1 = Content 1.1
 }}
| heading2 = Second subsection
 {{نوار جانبی|child=yes
  | heading1 = Heading 2.1
  | content1 = Content 2.1
 }}
| below = "below" text
}}

Note that omitting the الگو:پارا parameter and not including any text preceding the embedded sidebar may result in the creation of gaps by spurious blank rows.

سینتاکس کامل الگو

خطای لوآ: خطای داخلی: مفسر با وضعیت 1 خارج شده است.

(omitting heading4/content4 to penultimate heading/content parameters)

{{نوار جانبی
| name = {{subst:PAGENAME}}
| class =            <!-- or: | bodyclass = -->
| style =            <!-- or: | bodystyle = -->
| width = 
| cellspacing = 
| cellpadding = 
| wraplinks =        <!-- "true" otherwise (default:) omit -->

| outertitleclass = 
| outertitlestyle = 
| outertitle = 

| topimageclass = 
| topimagestyle = 
| topimage = 
| topcaptionstyle = 
| topcaption = 

| pretitleclass = 
| pretitlestyle = 
| pretitle = 

| titleclass = 
| title = 

| imageclass = 
| imagestyle = 
| image = 
| captionstyle = 
| caption = 

| headingclass = 
| headingstyle = 
| contentclass = 
| contentstyle = 

| aboveclass = 
| abovestyle = 
| above = 

| heading1style = 
| heading1 = 
| content1style = 
| content1 = 

| heading2style = 
| heading2 = 
| content2style = 
| content2 = 

| heading3style = 
| heading3 = 
| content3style = 
| content3 = 

<!-- etc, to: -->

| heading35style = 
| heading35 = 
| content35style = 
| content35 = 

| belowclass = 
| belowstyle = 
| below = 

| navbarstyle =      <!-- or: | tnavbarstyle = -->
| navbarfontstyle =  <!-- or: | tnavbarfontstyle = -->
| navbar =           <!-- or: | tnavbar = --> <!-- "off", "none", etc otherwise (default:) omit -->

}}

Supplementary documentation

Supplementary related documentation (concerning {{navbar}} use within a sidebar) is at Template:Navbar/doc.

همچنین ببینید