Jump to content

ماڈیول:بطاقة/قالب/مبنى

آزاد انسائیکلوپیڈیا، وکیپیڈیا توں

Documentation for this module may be created at ماڈیول:بطاقة/قالب/مبنى/doc

local generic = require( 'ماڈیول:بطاقة/أدوات' )
local building = require( 'ماڈیول:بطاقة/أدوات/مبنى' )

return {
  maincolor = '#CEDEFF' -- اللون المستعمل لعنوان البطاقة
  , wikimod = 'Wikidata.Ca'
  , parts = { -- محتويات البطاقة
    building.title(),
    {type = 'subtitle', 
        value = function ( localdata )
                    local val = localdata['الاسم الأصلي'] or localdata['اسم اصلي'] or localdata['native_name']
                    if val and localdata['لغة_الاسم_الأصلي']  then
                        return mw.ustring.format('%s <span class="nickname" lang="%s">%s</span>'
                            , val 
                            , localdata['الاسم_باللغة_الاصلية'] or ''
                            , localdata['لغة_الاسم_الأصلي']
                        )
                    end
                    return val
                end,
                wikidata= {property = 'P1559 OR P1476 OR P1448 OR P1705', list = 'notlang', conjunction = "<br />"
                    ,formatting = '$text {{Language icon|NoCat=y|$language}}'}
    },
    generic.logo(),
    building.mainimage(),
    generic.locationmap(),

	{type = 'table' , title ='التسمية' ,rows = {
		{type = 'row' 
			, label = 'أسماء سابقة'
			, value = {'أسماء_سابقة','former_names','former_name'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'أسماء بديلة'
			, value = {'أسماء_بديلة','alternate_names','alternate_name'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'معنى الاسم'
			, value = {'معنى_التسمية','etymology'}
			--, wikidata = {property='P'}
		},
        {type = 'row' , label = 'الاسم نسبة إلى' , 
                value = {'سبب_تسمية','namesake'} , 
                wikidata = {property = 'P138'}
        },
    }},
 	{type = 'table' , title ='معلومات عامة' ,rows = {
		{type = 'row' 
			, label = 'الحالة' 
            , value = {'الوضع_الحالي','status'}
 			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'نوع المبنى' 
            , value = {'نوع_المبنى','نوع','building_type'}
 			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'التصنيف'
			, value = {'التصنيف','الحماية','classification'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'الموقع'
			, value = {'الموقع','location'}
			, wikidata = {property = 'P276'}
		},
		{type = 'row' 
			, label = 'العنوان'
			, value = {'العنوان','address'}
			, wikidata = {property='P6375', list = 2, conjunction = "<br />"
                    ,formatting = '$text {{Language icon|NoCat=y|$language}}'}
		},
		{type = 'row' 
			, label = 'المدينة'
			, value = {'المدينة','location_town','location_city'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'التقسيم الإداري'
			, value = {'تقسيم','administrative_territorial'}
			, wikidata = {property = 'P131'}
		},
		building.country(),
		{type = 'row' 
			, label = {'grid_name'} , defaultlabel='Grid&nbsp;position'
			, value = {'grid_position'}
 			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'بني بطلب من' 
			, value = {'زبون','client'}
			, wikidata = {property='P88'}
		},
		{type = 'row' 
			, label = 'المالك' 
			, value = {'مالك','owner'}
			, wikidata = {property='P127'}
		},
		{type = 'row' 
			, label = 'الهيئة الإدارية'
			, value = {'هيئة إدارية','governing_body'}
 			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'مالك الأرض' 
			, value = {'مالك_الأرض','landlord'}
 			--, wikidata = {property='P'}
		},
		building.operator(),
		{type = 'row' 
			, label = 'الانتماء'
			, value = {'الانتماء','affiliation'}
			--, wikidata = {property='P'}
        },
		building.usage(),
        {type = 'row' , label = 'الساكن الحالي' , 
                value = {'المستأجر_الحالي','current_tenants'} , 
                wikidata = {property = 'P466', conjunction = '<br />'}
        },
    }},
 	{type = 'table' , title ='أبرز الأحداث' ,rows = {
		{type = 'row' 
                , label = 'تاريخ وضع حجر الأساس'
                , value = {'تاريخ_وضع_حجر_الأساس','groundbreaking_date'}
                --, wikidata = {property='P'}
		},
		{type = 'row' 
                , label = 'تاريخ بدء البناء'  
                , value = {'تاريخ_بدء_البناء','start_date','construction_start_date'}
                , wikidata = {property='P793', qualifier='P580 or P585', formatting='table', conjunction='<br />'
                        , rowformat='$1' , whitelist0='Q385378,Q27136782' }
		},
		{type = 'row' 
			, label = 'تاريخ توقف البناء'
			, value = {'stop_date','construction_stop_date'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'نهاية الأعمال الكبرى'
			, value = {'topped_out_date','نهاية_الأعمال_الكبرى'}
			, wikidata = {property='P793', qualifier='P585', formatting='table', conjunction='<br />'
                        , rowformat='$1' , whitelist0='Q1075723'}
		},
        {type = 'row' 
            , label = 'تاريخ الانتهاء' 
            , value = {'تاريخ_الإنتهاء','est_completion','completion_date'}
            , wikidata = {property='P793', qualifier='P582', formatting='table', conjunction='<br />'
                        , rowformat='$1' , whitelist0='Q385378'}
        },
        {type = 'row' 
            , label = 'تاريخ الافتتاح' 
            , value = {'تاريخ_الافتتاح','opened_date','opened','opening_date','opening'}
            --, wikidata = {property='P'}
        },
        {type = 'row' 
            , label = 'تاريخ الافتتاح الرسمي' 
            , value = {'تاريخ_الافتتاح_الرسمي','inauguration_date'}
            , wikidata = {property='P1619'}
        },
        {type = 'row' 
            , label = 'النقل' 
            , value = {'تاريخ_نقل_المبنى','relocated_date'}
            --, wikidata = {property='P'}
        },
        {type = 'row' 
            , label = 'التحديث' 
            , value = {'تاريخ_تحديث_المبنى','renovation_date'}
            --, wikidata = {property='P'}
        },
        {type = 'row' 
            , label = 'الإغلاق'
            , value = {'تاريخ_الاغلاق','closing_date'}
            --, wikidata = {property='P'}
        },        
		{type = 'row' 
			, label = 'الهدم'
			, value = {'تاريخ_هدم_المبنى','date_demolished','demolished_date'}
 			, wikidata = {property='P576', qualifier='P770', formatting='table', conjunction='<br />'
                        , rowformat='$0$R0 $1' , rowsubformat1='<small>($1)</small>'}
		},
		{type = 'row' 
			, label = 'التدمير'
			, value = {'تاريخ_تدمير_المبنى','destruction_date','destroyed'}
 			, wikidata = {property='P3082'}
		},
		{type = 'row' 
			, label = 'سبب الدمار'
			, value = {'سبب الدمار','cause of destruction'}
 			, wikidata = {property='P770'}
		},
		{type = 'row' 
			, label = 'تواريخ مهمة'
			, value = {'تواريخ_مهمة','significant_event'}
			, wikidata = {property = 'P793', formatting='table', conjunction='<br />'
                        , qualifier='P585' , rowformat='$0$R0 $1' , blacklist0='Q385378,Q1075723,Q27136782'
                        , rowsubformat1='<small>($1)</small>' 
                }
        },
    }},
    {type = 'table' , title ='[[ملف:World Heritage Logo.svg|20px]] [[موقع تراث عالمي|موقع اليونيسكو للتراث العالمي]]', 
            rows = {
                {type = 'row' , label = '[[موقع_تراث_عالمي#معايير_الاختيار|المعايير]]' , 
                        value = {'معيار_موقع_تراث_عالمي'} , 
                        wikidata = {property = 'P2614', conjunction = "<br />"}
                },
                {type = 'row' , label = 'رقم التعريف' , 
                        value = {'رقم_موقع_تراث_عالمي'} , 
                        wikidata = {property = 'P757'}
                },
    }},
 	{type = 'table' , title ='ارتفاع المبنى' ,rows = {
        {type = 'row' 
			, label = 'أرقام قياسية'
			, value = function(localdata)
                    if( type(localdata['highest_start']) ~= 'string' 
                    and type(localdata['highest_end']) ~= 'string') then return end
                    local r
                    r = 'Tallest in '.. (localdata['highest_region'] or 'the world')
                    if( localdata['highest_start'] and localdata['highest_end'])
                    then r = mw.ustring.format('%s from %s to %s'
                    , r 
                    , localdata['highest_start']
                    , localdata['highest_end']
                    )
                    elseif( localdata['highest_start']) 
                    then r = mw.ustring.format('%s since %s'
                    , r 
                    , localdata['highest_start']
                    )
                    elseif( localdata['highest_end'])
                    then r = mw.ustring.format('%s until %s'
                    , r 
                    , localdata['highest_end']
                    )
                    end
                    return r.. '{{ref label|'..(localdata['highest_reflabel'] or 'talleststatus')..'|I|}}'
                end
 			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = ':: تجاوز'
			, value = {'highest_prev'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = ':: تجاوزه'
			, value = {'highest_next'}
			--, wikidata = {property='P'}
        },

		{type = 'row' 
			, label = 'الارتفاع عن سطح البحر'
			, value = {'ارتفاع_عن_البحر','altitude'}
            , wikidata = {property = 'P2044', formatting='unitlinked'}
		},
		{type = 'row' 
			, label = 'الارتفاع'
			, value = {'ارتفاع','height'}
			, wikidata = {property='P2048', list='bestrank',colformat0='unitlinked', formatting='table'
                        , conjunction='<br />', qualifier='P518' , rowformat='$0$R0 $1' 
                        , rowsubformat1='<small>($1)</small>' }
		},
		{type = 'row' 
			, label = 'المعماري'
			, value = {'الارتفاع_المعماري','architectural'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'أعلى نقطة'
			, value = {'أعلى نقطة','tip'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'برج الهوائي'
			, value = {'برج_الهوائي','antenna_spire'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'السقف'
			, value = {'سقف','roof'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'أعلى طابق'
			, value = {'أعلى_طابق','top_floor'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'أعلى نقطة مراقبة'
			, value = {'أعلى_نقطة_مراقبة','observatory'}
			--, wikidata = {property='P'}
        },
    }},
 	{type = 'table' , title ='الأبعاد' ,rows = {
        {type = 'row' , label = 'المساحة' , 
                value = {'مساحة'} , 
                wikidata = {property = 'P2046', formatting='table', conjunction='<br />'
                        , qualifier='P518' , rowformat='$0$R0 $1' 
                        , rowsubformat1='<small>($1)</small>' ,colformat0 = 'unitlinked'
                }
        },
        {type = 'row' , label = 'الطول' , 
                value = {'طول'} , 
                wikidata = {property = 'P2043', formatting='unitlinked'}
        },
        {type = 'row' , label = 'العرض' , 
                value = {'عرض'} , 
                wikidata = {property = 'P2049', formatting='unitlinked'}
        },        
		{type = 'row' 
			, label = 'القطر'
			, value = {'قطر','قطر_المبنى','diameter'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'محيط الدائرة'
			, value = {'محيط','محيط_المبنى','circumference'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'الوزن'
			, value = {'وزن','weight'}
			, wikidata = {property='P2067', formatting='unitlinked'}
		},
		{type = 'row' 
			, label = 'Size'
			, value = {'size'}
			--, wikidata = {property='P'}
		},
		{type = 'row' 
			, label = 'أبعاد أخرى'
			, value = {'أبعاد أخرى','other_dimensions'}
			--, wikidata = {property='P'}
        },
    }},
    {type = 'table' , title ='التفاصيل التقنية', rows = {
        {type = 'row' , label = 'يضم' , 
                value = {'يضم','parts'} , 
                wikidata = {property = 'P527', conjunction = '<br />'}
        },
        {type = 'row' , label = 'جزء من' , 
                value = {'جزء_من','part_of'} , 
                wikidata = {property = 'P361', conjunction = '<br />'}
        },
            {type = 'row' , label = 'النظام الهيكلي' , 
                    value = {'structural_system','النظام_الهيكلي'}
            },
            {type = 'row' , label = 'المواد المستخدمة' , 
                    value = {'المواد_المستخدمة','material'} , 
                    wikidata = {property = 'P186' , qualifier = 'P518', formatting='table', conjunction='<br />'
                              , rowformat='$0$R0 $1' 
                              , rowsubformat1='<small>($1)</small>'} 
            },
		{type = 'row' 
			, label = 'عدد الطوابق'
			, value = {'عدد الطوابق','floor_count','floors'}
			--, wikidata = {property='P'}
		},
        {type = 'row' , label = 'طوابق فوق الأرض' , 
                value = {'طوابق_فوق_الأرض','floors above ground'} , 
                wikidata = {property = 'P1101'}
        },
        {type = 'row' , label = 'طوابق تحت الأرض' , 
                value = {'طوابق تحت الأرض','floors below ground'} , 
                wikidata = {property = 'P1139'}
        },
        {type = 'row' , label = 'مساحة الطابق' , 
                value = {'مساحة_الطابق_الواحد','floor_area'}
        },
        {type = 'row' , label = 'عدد المصاعد' , 
                value = {'عدد_المصاعد','elevator_count'} , 
                wikidata = {property = 'P1301'}
        },
        {type = 'row' , label = 'مساحة الأرض' , 
                value = {'مساحة_الأرض','grounds_area'}
        },
    }},
 	{type = 'table' , title ='التصميم والإنشاء' ,rows = {
        {type = 'row' , label = 'النمط المعماري' , 
                value = {'النمط_المعماري','طراز_معماري','architectural_style','style'} , 
                wikidata = {property = 'P149'}
        },
        {type = 'row' , label = 'المهندس المعماري' , 
                value = {'المهندس_المعماري','architect'} , 
                wikidata = {property = 'P84', conjunction='<br />'}
        },
        {type = 'row' , label = 'المصمم' , 
                value = {'المصمم','designer'}
        },
        {type = 'row' , label = 'مصممون آخرون' , 
                value = {'مصممين_آخرون','other_designers'}
        },
        {type = 'row' , label = 'المطور' , 
                value = {'developer','المطور'}
        },
        {type = 'row' , label = 'شركة البناء' , 
                value = {'شركة_البناء','architecture_firm'}
        },
        {type = 'row' , label = {'تسمية مقاول'} , defaultlabel ='المقاول الرئيسي',
                value = {'المقاول_الرئيسي','main_contractor','main_contractors'} , 
                wikidata = {property = 'P193', conjunction='<br />'}
        },
        {type = 'row' , label = 'المهندس' , 
                value = {'مهندس','engineer'}
        },
        {type = 'row' , label = 'المهندس الإنشائي' , 
                value = {'المهندس_الانشائي','structural_engineer'} , 
                wikidata = {property = 'P631', conjunction='<br />'}
        },
        {type = 'row' , label = 'مهندس الخدمات' , 
                value = {'مهندس_الخدمات','services_engineer'}
        },
        {type = 'row' , label = 'المهندس المدني' , 
                value = {'المهندس_المدني','civil_engineer'}
        },
        {type = 'row' , label = 'Quantity surveyor' , 
                value = {'quantity_surveyor'}
        },
        generic.awards(),
        {type = 'row' , label = 'الألقاب' , 
                value = {'الألقاب','designations'}
        },
        {type = 'row' , label = 'معروف بـ' , 
                value = {'معروف','known_for'}
        },
		{type = 'row' 
			, label = 'التكلفة'
			, value = {'تكلفة_المبنى','cost'}
			, wikidata = {property='P2130',formatting='unitlinked'}
		},
    }},
    generic.planview(),
    {type = 'table' , title ='فريق التجديد', rows = {
        {type = 'row' , label = 'المهندس المعماري' , 
                value = {'ren_architect'}
        },
        {type = 'row' , label = 'شركة التجديد' , 
                value = {'ren_firm'}
        },
        {type = 'row' , label = 'المهندس' , 
                value = {'ren_engineer'}
        },
        {type = 'row' , label = 'المهندس الإنشائي' , 
                value = {'ren_str_engineer'}
        },
        {type = 'row' , label = 'مهندس الخدمات' , 
                value = {'ren_serv_engineer'}
        },
        {type = 'row' , label = 'المهندس المدني' , 
                value = {'ren_civ_engineer'}
        },
        {type = 'row' , label = 'مصممون آخرون' , 
                value = {'ren_oth_designers'}
        },
        {type = 'row' , label = 'Quantity surveyor' , 
                value = {'ren_qty_surveyor'}
        },
        {type = 'row' , label = 'المقاول الرئيسي' , 
                value = {'ren_contractor'}
        },
        {type = 'row' , label = 'الجوائز والمكافآت' , 
                value = {'ren_awards'}
        },
		{type = 'row' 
			, label = 'تكلفة التحديث'
			, value = {'تكلفة_التحديث','ren_cost'}
			--, wikidata = {property='P'}
		},
    }},

    {type = 'table' , title ='معلومات أخرى', rows = {
		{type = 'row' 
			, label = 'سلسلة الفنادق'
			, value = {'سلسلة','سلسلة الفنادق','hotel_chain','chain'}
			--, wikidata = {property='P'}
        },
        {type = 'row' , label = 'نوع المقاعد' , 
                value = {'seating_type'}
        },
        {type = 'row' , label = 'الطاقة الاستيعابية' , 
                value = {'seating_capacity','capacity'}
        },
        {type = 'row' , label = 'عدد المتاجر' , 
                value = {'number_of_stores'}
        },
        {type = 'row' , label = 'عدد  المراسي' , 
                value = {'number_of_anchors'}
        },
        {type = 'row' , label = 'عدد الغرف' , 
                value = {'عدد_الغرف','number_of_rooms','room_count','rooms'}
        },
        {type = 'row' , label = 'عدد الوحدات' , 
                value = {'number_of_units','unit_count','عدد_الوحدات'}
        },
        {type = 'row' , label = 'عدد الأجنحة' , 
                value = {'عدد_الأجنحة','number_of_suites','suite_count','suites'}
        },
        {type = 'row' , label = 'عدد المطاعم' , 
                value = {'عدد_المطاعم','number_of_restaurants'}
        },
        {type = 'row' , label = 'عدد الحانات' , 
                value = {'عدد_الحانات','number_of_bars'}
        },
        {type = 'row' , label = 'Facilities' , 
                value = {'facilities'}
        },
        {type = 'row' , label = 'مواقف السيارات' , 
                value = {'كراج_السيارات','مواقف_السيارات'}
        },
        {type = 'row' , label = 'عدد الزوار سنوياً' , 
                value = {'عدد الزوار'} , 
                wikidata = {property = 'P1174', qualifier = 'P585', formatting='table'
                              , list='bestrank', conjunction='<br />', rowformat='$0$R0 $1' 
                              , rowsubformat1='<small>($1)</small>'}
        },
        building.website(),
        {type = 'row' , label = 'الحجز الإلكتروني' , 
                value = {'الحجز_الإلكتروني'}
        },
        {type = 'row' , label = 'رقم الهاتف' , 
                value = {'رقم الهاتف','رقم_الهاتف'} , 
                wikidata = {property = 'P1329'},
                valueStyle = {direction='LTR',['text-align'] = 'left'}
        },
        {type = 'row' , label = 'الرمز البريدي' , 
                value = {'الرمز_البريدي'} , 
                wikidata = {property = 'P281'}
        },
        building.coordinates(),
    }},

    generic.geoloc(),
 	{type = 'table' ,rows = {
        --, content ={'nrhp','embedded','module'}
    }},
 }
}