Actions

Template

ResourcePage: Difference between revisions

From Dune Awakening DB

mNo edit summary
mNo edit summary
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
<div class="dune-breadcrumb-nav">
<templatestyles src="Template:ResourcePage/styles.css" />{{#get_external_data:source=externaldb|from=data_items|data=ItemID=item_id,InternalName=internal_name,ItemClass=item_class,ItemSubclass=item_subclass,Tier=tier,Rarity=rarity,Faction=faction,Name=name,Description=description,HowToObtain=how_to_obtain,Notes=notes,AdditionalNotes=additional_notes,Weight=weight,MaxStacks=max_stacks,XPPerHarvest=xp_per_harvest,BaseVendorPrice=base_vendor_price,GuideLink=guide_link,IconLink=icon_link,ImageLink=image_link,Category1=category_1,Category2=category_2,Category3=category_3|cache=yes|where=name='{{PAGENAME}}'|limit=1
  <templatestyles src="Template:ResourcePage/styles.css" />
}}
  {{#get_external_data:
{{#for_external_table:|{{#vardefine:ItemID|{{{ItemID}}}}}{{#vardefine:InternalName|{{{InternalName}}}}}{{#vardefine:ItemClass|{{{ItemClass}}}}}{{#vardefine:ItemSubclass|{{{ItemSubclass}}}}}{{#vardefine:Tier|{{{Tier}}}}}{{#vardefine:Rarity|{{{Rarity}}}}}{{#vardefine:Faction|{{{Faction}}}}}{{#vardefine:Name|{{{Name}}}}}{{#vardefine:Description|{{{Description}}}}}{{#vardefine:HowToObtain|{{{HowToObtain}}}}}{{#vardefine:Notes|{{{Notes}}}}}{{#vardefine:AdditionalNotes|{{{AdditionalNotes}}}}}{{#vardefine:Weight|{{{Weight}}}}}{{#vardefine:MaxStacks|{{{MaxStacks}}}}}{{#vardefine:XPPerHarvest|{{{XPPerHarvest}}}}}{{#vardefine:BaseVendorPrice|{{{BaseVendorPrice}}}}}{{#vardefine:GuideLink|{{{GuideLink}}}}}{{#vardefine:IconLink|{{{IconLink}}}}}{{#vardefine:ImageLink|{{{ImageLink}}}}}{{#vardefine:Category1|{{{Category1}}}}}{{#vardefine:Category2|{{{Category2}}}}}{{#vardefine:Category3|{{{Category3}}}}}
    source=externaldb
    |from=data_items
    |data=ItemID=item_id,InternalName=internal_name,ItemClass=item_class,ItemSubclass=item_subclass,Tier=tier,Rarity=rarity,Faction=faction,Name=name,Description=description,HowToObtain=how_to_obtain,Notes=notes,AdditionalNotes=additional_notes,Weight=weight,MaxStacks=max_stacks,XPPerHarvest=xp_per_harvest,BaseVendorPrice=base_vendor_price,GuideLink=guide_link,IconLink=icon_link,ImageLink=image_link,Category1=category_1,Category2=category_2,Category3=category_3
    |cache=yes
    |where=name='{{PAGENAME}}'
    |limit=1
   }}
   }}
  {{#for_external_table:|
    {{#vardefine:ItemID|{{{ItemID}}}}}{{#vardefine:InternalName|{{{InternalName}}}}}{{#vardefine:ItemClass|{{{ItemClass}}}}}{{#vardefine:ItemSubclass|{{{ItemSubclass}}}}}{{#vardefine:Tier|{{{Tier}}}}}{{#vardefine:Rarity|{{{Rarity}}}}}{{#vardefine:Faction|{{{Faction}}}}}{{#vardefine:Name|{{{Name}}}}}{{#vardefine:Description|{{{Description}}}}}{{#vardefine:HowToObtain|{{{HowToObtain}}}}}{{#vardefine:Notes|{{{Notes}}}}}{{#vardefine:AdditionalNotes|{{{AdditionalNotes}}}}}{{#vardefine:Weight|{{{Weight}}}}}{{#vardefine:MaxStacks|{{{MaxStacks}}}}}{{#vardefine:XPPerHarvest|{{{XPPerHarvest}}}}}{{#vardefine:BaseVendorPrice|{{{BaseVendorPrice}}}}}{{#vardefine:GuideLink|{{{GuideLink}}}}}{{#vardefine:IconLink|{{{IconLink}}}}}{{#vardefine:ImageLink|{{{ImageLink}}}}}{{#vardefine:Category1|{{{Category1}}}}}{{#vardefine:Category2|{{{Category2}}}}}{{#vardefine:Category3|{{{Category3}}}}}
  }}
  <span id="menuRadialTrigger" class="menu-button-wrapper" style="cursor:pointer;">[[File:MenuButton.png|100px|link=|alt=Menu]]</span><span class="dune-breadcrumb-separator">/</span>[[{{#var:Category1}}|{{#var:Category1}}]]<span class="dune-breadcrumb-separator">/</span>[[{{#var:Category2}}|{{#var:Category2}}]]<span class="dune-breadcrumb-separator">/</span>[[{{#var:Category3}}|{{#var:Category3}}]]<span class="dune-breadcrumb-separator">/</span><span>{{PAGENAME}}</span>
</div>
<div class="responsive-container">
<div class="responsive-container">
<div class="responsive-col col1">
<div class="responsive-col col1">
Line 60: Line 49:
<h3 class="dune-section-header">Crafted With</h3>
<h3 class="dune-section-header">Crafted With</h3>
<div class="dune-card-description">Items that require {{#var:Name}} as an ingredient</div>
<div class="dune-card-description">Items that require {{#var:Name}} as an ingredient</div>
<div class="recipe-search-container"><input type="text" id="craftedWithSearch" class="recipe-search-input" placeholder="Search recipes..."></div>
<div id="craftedWithPreview" class="recipe-table-preview">
<div id="craftedWithPreview" class="recipe-table-preview">
{{#get_external_data:
{{#get_external_data:
Line 70: Line 58:
|order by=Stations
|order by=Stations
|limit=5
|limit=5
|table=crafted_with_preview
}}
}}
<!-- For Crafted With section, after the table -->
<!-- For Crafted With section, after the table -->
Line 85: Line 74:
<div class="dune-table-wrapper">
<div class="dune-table-wrapper">
<table class="infobox-dune-standard-table recipe-table" id="craftedWithTable">
<table class="infobox-dune-standard-table recipe-table" id="craftedWithTable">
<thead><tr class="tr-dark"><th style="width:35%;">Item Created</th><th style="width:40%;">Resources Needed</th><th style="width:25%;">Stations</th></tr></thead>
<tr class="tr-dark"><th style="width:35%;">Item Created</th><th style="width:40%;">Resources Needed</th><th style="width:25%;">Stations</th></tr>
<tbody>{{#for_external_table:|<tr class="recipe-row"><td>{{#invoke:DataTableParserV2|iconize|{{{OutputItem}}}}}</td><td>{{#invoke:DataTableParserV2|formatRecipeList|{{{Resources}}}}}</td><td>{{{Stations}}}</td></tr>}}</tbody>
{{#for_external_table:|<tr class="recipe-row"><td>{{#invoke:DataTableParserV2|iconize|{{{OutputItem}}}}}</td><td>{{#invoke:DataTableParserV2|formatRecipeList|{{{Resources}}}}}</td><td>{{{Stations}}}</td></tr>}}
</table>
</table>
</div>
</div>
</div>
</div>
<div class="recipe-actions"><button class="dune-action-button view-all-crafted-with" data-resource="{{PAGENAME}}"><span class="icon">📋</span> View All Recipes</button></div>
<div class="recipe-actions"><span class="dune-action-button view-all-crafted-with" data-resource="{{PAGENAME}}">View All Recipes</span></div>
</div>
</div>
<div style="clear:both; padding:10px;"></div>
<div style="clear:both; padding:10px;"></div>
Line 96: Line 85:
<h3 class="dune-section-header">Crafted From</h3>
<h3 class="dune-section-header">Crafted From</h3>
<div class="dune-card-description">Recipes that produce {{#var:Name}}</div>
<div class="dune-card-description">Recipes that produce {{#var:Name}}</div>
<div class="recipe-search-container"><input type="text" id="craftedFromSearch" class="recipe-search-input" placeholder="Search recipes..."></div>
<div id="craftedFromPreview" class="recipe-table-preview">
<div id="craftedFromPreview" class="recipe-table-preview">
{{#get_external_data:
{{#get_external_data:
Line 117: Line 105:
|where=output_item='{{PAGENAME}}'
|where=output_item='{{PAGENAME}}'
|order by=station
|order by=station
|table=crafted_from_preview
}}
}}
</div>
</div>
<div class="dune-table-wrapper">
<div class="dune-table-wrapper">
<table class="infobox-dune-standard-table recipe-table" id="craftedFromTable">
<table class="infobox-dune-standard-table recipe-table" id="craftedFromTable">
<thead><tr class="tr-dark"><th style="width:35%;">Item Created</th><th style="width:40%;">Resources Needed</th><th style="width:25%;">Stations</th></tr></thead>
<tr class="tr-dark"><th style="width:35%;">Item Created</th><th style="width:40%;">Resources Needed</th><th style="width:25%;">Stations</th></tr>
<tbody>{{#for_external_table:|<tr class="recipe-row"><td>{{#invoke:DataTableParserV2|iconize|{{{OutputItem}}}}}</td><td>{{#invoke:DataTableParserV2|formatRecipeList|{{{Resources}}}}}</td><td>{{{Stations}}}</td></tr>}}</tbody>
{{#for_external_table:|<tr class="recipe-row"><td>{{#invoke:DataTableParserV2|iconize|{{{OutputItem}}}}}</td><td>{{#invoke:DataTableParserV2|formatRecipeList|{{{Resources}}}}}</td><td>{{{Stations}}}</td></tr>}}
</table>
</table>
</div>
</div>
</div>
</div>
<div class="recipe-actions"><button class="dune-action-button view-all-crafted-from" data-resource="{{PAGENAME}}"><span class="icon">📋</span> View All Recipes</button></div>
<div class="recipe-actions"><span class="dune-action-button view-all-crafted-from" data-resource="{{PAGENAME}}">View All Recipes</span></div>
</div>
</div>
</div>
</div>
Line 133: Line 122:
</div>
</div>
<div class="responsive-col col3">
<div class="responsive-col col3">
<div class="skin-pivot">
    <!-- Building Guide Video Card with Notes integrated -->
<div class="dune-card">
    <div class="skin-pivot">
<div class="dune-card-decoration"></div>
      <div class="dune-card">
<div class="dune-card-inner">
        <div class="dune-card-decoration"></div>
{{#get_external_data:
        <div class="dune-card-inner">
source=externaldb
          <div class="dune-card-label">VIDEO TUTORIALS</div>
|from=data_item_videos
          <div class="dune-card-title"><span class="icon">▶</span> Building Guide</div>
|data=VideoID=video_id,Context=context,Featured=featured
          <div style="padding:3px;"></div>
|cache=yes
          <div class="dune-card-video">
|where=internal_name='{{PAGENAME}}'
            {{#if:{{{YoutubeEmbed|}}}|  
|limit=1
              {{{YoutubeEmbed}}}
}}
            |  
<div class="dune-card-label">VIDEO TUTORIALS</div>
              <youtube id="r8lxVDqoHLQ" />
<div class="dune-card-title"><span class="icon">▶</span> Resource Guide</div>
            }}
{{#if:{{{VideoID|}}}|<div class="dune-card-video" style="border:2px solid #e2d3ae;border-radius:4px;padding:2px;background-color:#262626;"><youtube>{{#var:VideoID}}</youtube></div>|{{#if:{{#var:GuideLink}}|<div class="dune-card-video" style="border:2px solid #e2d3ae;border-radius:4px;padding:2px;background-color:#262626;"><youtube>{{#var:GuideLink}}</youtube></div>|<div class="dune-card-video" style="border:2px solid #e2d3ae;border-radius:4px;padding:2px;background-color:#262626;"><youtube>r8lxVDqoHLQ</youtube></div>}}
          </div>
<div style="clear:both; padding:10px;"></div>
          <div style="clear:both; padding:10px;"></div>
{{#get_external_data:
 
source=externaldb
          <div class="dune-card-title"><span class="icon"></span> Notes</div>
|from=data_item_gallery
          <div style="padding:3px;"></div>
|data=ImageURL=image_url,Caption=caption
          <div class="dune-card-description">{{#invoke:DataTableParserV2|iconize|{{#var:AdditionalNotes}}}}</div>
|cache=yes
        </div>
|where=internal_name='{{PAGENAME}}'
      </div>
|order by=position
    </div>
|limit=4
}}
{{#if:{{{ImageURL|}}}|<div class="dune-card-label">IMAGE GALLERY</div><div style="padding:3px;"></div><div class="gallery-container">{{#for_external_table:|<div class="gallery-item">[[File:{{{ImageURL}}}|120px|alt={{{Caption}}}]]{{#if:{{{Caption|}}}|<div class="caption">{{{Caption}}}</div>|}}</div>}}</div>}
<div style="clear:both; padding:10px;"></div>
<div class="dune-card-title"><span class="icon"></span> Notes</div>
<div style="padding:3px;"></div>
<div class="dune-card-description">{{#invoke:DataTableParserV2|iconize|{{#var:AdditionalNotes}}}}</div>
</div>
</div>
</div>
</div>
</div>
{{#tag:script|
<nowiki>
<div class="recipe-popup-overlay">
  <div class="recipe-popup">
    <div class="popup-header">
      <h3 class="popup-title">{{title}}</h3>
      <button class="popup-close">×</button>
    </div>
    <div class="popup-content">
      <div class="popup-search-container">
        <input type="text" class="popup-search-input" placeholder="Search recipes…">
      </div>
      <div class="popup-table-wrapper">
        <table class="infobox-dune-standard-table recipe-popup-table">
          <thead>
            <tr class="tr-dark">
              <th>Item Created</th><th>Resources Needed</th><th>Stations</th>
              <th>Water&nbsp;(mL)</th><th>Craft&nbsp;Time</th><th>Schematic</th>
            </tr>
          </thead>
          <tbody>{{tableRows}}</tbody>
        </table>
      </div>
    </div>
  </div>
</div>
</div>
<script id="recipePopupTemplate" type="text/template">
</nowiki>
<div class="recipe-popup-overlay"><div class="recipe-popup"><div class="popup-header"><h3 class="popup-title">{{title}}</h3><button class="popup-close">×</button></div><div class="popup-content"><div class="popup-search-container"><input type="text" class="popup-search-input" placeholder="Search recipes..."></div><div class="popup-table-wrapper"><table class="infobox-dune-standard-table recipe-popup-table"><thead><tr class="tr-dark"><th>Item Created</th><th>Resources Needed</th><th>Stations</th><th>Water (mL)</th><th>Craft Time</th><th>Schematic</th></tr></thead><tbody>{{tableRows}}</tbody></table></div></div></div></div>
|type="text/template" id="recipePopupTemplate"}}
</script>

Latest revision as of 01:49, 4 June 2025

{{{ItemClass}}} - {{{ItemSubclass}}}
Resource Information
[[File:{{{ImageLink}}}|200px|alt={{{Name}}}]]
{{{Description}}}
[[File:{{{IconLink}}}|16px]] Tier{{{Tier}}}
Rarity{{{Rarity}}}
🏛 Faction{{{Faction}}}
Weight{{{Weight}}} kg
📦 Max Stacks{{{MaxStacks}}}
💰 Base Vendor Price{{{BaseVendorPrice}}} Solaris
XP per Harvest{{{XPPerHarvest}}}


CRAFTING
Crafting Recipes

Crafted With

Items that require {{{Name}}} as an ingredient
Item CreatedResources NeededStations
View All Recipes

Crafted From

Recipes that produce {{{Name}}}
Item CreatedResources NeededStations
View All Recipes
VIDEO TUTORIALS
Building Guide
Notes
{{{AdditionalNotes}}}

<script type="text/template" id="recipePopupTemplate"> <div class="recipe-popup-overlay"> <div class="recipe-popup"> <div class="popup-header"> <h3 class="popup-title">{{title}}</h3> <button class="popup-close">×</button> </div> <div class="popup-content"> <div class="popup-search-container"> <input type="text" class="popup-search-input" placeholder="Search recipes…"> </div> <div class="popup-table-wrapper"> <table class="infobox-dune-standard-table recipe-popup-table"> <thead> <tr class="tr-dark"> <th>Item Created</th><th>Resources Needed</th><th>Stations</th> <th>Water (mL)</th><th>Craft Time</th><th>Schematic</th> </tr> </thead> <tbody>{{tableRows}}</tbody> </table> </div> </div> </div> </div> </script>