Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.
Created page with "# Secrets of Hogwarts - Navpills Template ## Template:Navpills ```wiki <includeonly>{{#invoke:Navpills|navpills}}</includeonly><noinclude> Navpills is used to create a grid of navigation buttons for exploring the magical world of 2085. It is powered by Module:Navpills. == Example == <pre><nowiki> {{Navpills |page1 = Professor Helena Chen |page2 = Gryffindor House 2085 |page3 = Room of Requirement 2085 |text3 = Hidden Mysteries |image3 = Room-of-requirement-2085.jp..."
 
No edit summary
Line 1: Line 1:
# Secrets of Hogwarts - Navpills Template
## Template:Navpills
```wiki
<includeonly>{{#invoke:Navpills|navpills}}</includeonly><noinclude>
<includeonly>{{#invoke:Navpills|navpills}}</includeonly><noinclude>
Navpills is used to create a grid of navigation buttons for exploring the magical world of 2085. It is powered by [[Module:Navpills]].
Navpills is used to create a grid of navigation buttons for exploring the magical world of 2085. It is powered by [[Module:Navpills]].
Line 159: Line 154:
[[Category:Secrets of Hogwarts templates]]
[[Category:Secrets of Hogwarts templates]]
</noinclude>
</noinclude>
```
## Module:Navpills (Lua Module)
```lua
local p = {}
function p.navpills(frame)
    local args = frame:getParent().args
    local output = {}
   
    -- Start container
    table.insert(output, '<div class="navpills-container">')
   
    -- Process up to 12 pages
    for i = 1, 12 do
        local page = args['page' .. i]
        if page and page ~= '' then
            local text = args['text' .. i] or page
            local image = args['image' .. i] or 'Default-portal.webp'
            local desc = args['desc' .. i] or 'Explore this section'
           
            -- Create navpill
            table.insert(output, '<div class="navpill">')
           
            -- Image section
            table.insert(output, '<div class="navpill-image">')
            table.insert(output, '[[File:' .. image .. '|120px|link=' .. page .. ']]')
            table.insert(output, '</div>')
           
            -- Content section
            table.insert(output, '<div class="navpill-content">')
            table.insert(output, '<h3 class="navpill-title">[[' .. page .. '|' .. text .. ']]</h3>')
            table.insert(output, '<div class="navpill-description">' .. desc .. '</div>')
            table.insert(output, '</div>')
           
            -- Close navpill
            table.insert(output, '</div>')
        end
    end
   
    -- Close container
    table.insert(output, '</div>')
   
    return table.concat(output)
end
return p
```

Revision as of 19:44, 6 August 2025

Navpills is used to create a grid of navigation buttons for exploring the magical world of 2085. It is powered by Module:Navpills.

Example

{{Navpills
|page1 = Professor Helena Chen
|page2 = Gryffindor House 2085
|page3 = Room of Requirement 2085
|text3 = Hidden Mysteries
|image3 = Room-of-requirement-2085.jpg
|page4 = Quantum Spires
|text4 = Magical Technology
|image4 = Quantum-spires-tower.jpg
}}

will give:

Parameters

  • pageN - The target page (e.g., "Hogwarts Library 2085")
  • textN - Custom display text (optional, defaults to page name)
  • imageN - Image file for the portal (optional, uses default if not specified)
  • descN - Brief description for the portal (optional)

Common Usage Examples

Castle Locations

{{Navpills
|page1 = Great Hall 2085
|page2 = Hogwarts Library 2085
|page3 = Astronomy Tower 2085
|page4 = Forbidden Forest 2085
}}

Academic Departments

{{Navpills
|page1 = Transfiguration Department 2085
|text1 = Quantum Transfiguration
|page2 = Potions Department 2085
|text2 = Bio-Digital Potions
|page3 = Defense Against the Dark Arts 2085
|text3 = Digital Defense
|page4 = Charms Department 2085
|text4 = Micro-Enchantments
}}

House Portals

{{Navpills
|page1 = Gryffindor House 2085
|image1 = Gryffindor-2085-crest.jpg
|page2 = Slytherin House 2085
|image2 = Slytherin-2085-crest.jpg
|page3 = Ravenclaw House 2085
|image3 = Ravenclaw-2085-crest.jpg
|page4 = Hufflepuff House 2085
|image4 = Hufflepuff-2085-crest.jpg
}}

Faculty Members

{{Navpills
|page1 = Professor Helena Chen
|text1 = Quantum Enchantments
|image1 = Professor-chen-portrait.jpg
|page2 = Professor Amara Okonkwo
|text2 = Bio-Potion Integration
|image2 = Professor-okonkwo-portrait.jpg
|page3 = Professor Kai Nakamura
|text3 = Digital Defense
|image3 = Professor-nakamura-portrait.jpg
}}

Student Organizations

{{Navpills
|page1 = The Mystery Solving Club
|text1 = Uncover Secrets
|page2 = Quantum Magic Research Society
|text2 = Advanced Theory
|page3 = Digital Divination Club
|text3 = Modern Fortune-telling
|page4 = Student Innovation Showcase
|text4 = Creative Inventions
}}

Timeline Exploration

{{Navpills
|page1 = The Integration Wars (2035-2045)
|text1 = Magical Conflicts
|page2 = The Great Revelation (2025-2035)
|text2 = Magic Goes Public
|page3 = The Digital Dark Ages (2030-2060)
|text3 = Lost Decades
|page4 = The Synthesis Period (2045-2065)
|text4 = Unity Era
}}

Hidden Mysteries

{{Navpills
|page1 = The Chen Constellation Mystery
|text1 = Professor's Secret
|page2 = The Great Library Incident of 2052
|text2 = Impossible Geometries
|page3 = Operation Mindbridge
|text3 = Consciousness Transfer
|page4 = The Room of Requirement Access Investigation
|text4 = Finding the Hidden Room
}}

Magical Technology

{{Navpills
|page1 = Quantum Spires
|text1 = Castle Architecture
|page2 = Smart Stone Technology
|text2 = Adaptive Buildings
|page3 = Holographic Spell Casting
|text3 = Digital Magic
|page4 = AI Magical Assistants
|text4 = Intelligent Help
}}

See Also