Update
This commit is contained in:
parent
0f25f779fe
commit
1b22a9b3c7
|
@ -8,7 +8,7 @@
|
||||||
<meta property="og:title" content="$(vars(:title))">
|
<meta property="og:title" content="$(vars(:title))">
|
||||||
<meta property="og:description" content="$(vars(:description))">
|
<meta property="og:description" content="$(vars(:description))">
|
||||||
<meta property="og:type" content="website">
|
<meta property="og:type" content="website">
|
||||||
<meta property="og:image" content="">
|
<meta property="og:image" content="/img/common/flag.png">
|
||||||
<meta property="og:url" content="">
|
<meta property="og:url" content="">
|
||||||
<link rel="icon" type="image/png" href="/favicon.png"/>
|
<link rel="icon" type="image/png" href="/favicon.png"/>
|
||||||
|
|
||||||
|
|
|
@ -16,55 +16,149 @@ dict_layouts = Dict(
|
||||||
:partners => generate_layout_html("main",controller,"partners",libraries=["Leaflet"]),
|
:partners => generate_layout_html("main",controller,"partners",libraries=["Leaflet"]),
|
||||||
)
|
)
|
||||||
|
|
||||||
#---General-----------------------------------------------------
|
#---Page info-----------------------------------------------------
|
||||||
|
|
||||||
|
const landing_info = Dict(
|
||||||
|
"en" => Dict(
|
||||||
|
:title => "LibSoc - A Global Network of Libertarian Socialists",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
"ru" => Dict(
|
||||||
|
:title => "LibSoc - Глобальная сеть либертарных социалистов",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
)
|
||||||
|
|
||||||
|
const manifesto_info = Dict(
|
||||||
|
"en" => Dict(
|
||||||
|
:title => "LibSoc - Manifesto",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
"ru" => Dict(
|
||||||
|
:title => "LibSoc - Манифест",
|
||||||
|
:description => ""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
const join_us_info = Dict(
|
||||||
|
"en" => Dict(
|
||||||
|
:title => "LibSoc - Manifesto",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
"ru" => Dict(
|
||||||
|
:title => "LibSoc - Присоединяйся",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
)
|
||||||
|
|
||||||
|
const groups_info = Dict(
|
||||||
|
"en" => Dict(
|
||||||
|
:title => "LibSoc - Groups",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
"ru" => Dict(
|
||||||
|
:title => "LibSoc - Группы",
|
||||||
|
:description => ""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
const cooperatives_info = Dict(
|
||||||
|
"en" => Dict(
|
||||||
|
:title => "LibSoc - Cooperatives",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
"ru" => Dict(
|
||||||
|
:title => "LibSoc - Кооперативы",
|
||||||
|
:description => ""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
const communities_info = Dict(
|
||||||
|
"en" => Dict(
|
||||||
|
:title => "LibSoc - Communities",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
"ru" => Dict(
|
||||||
|
:title => "LibSoc - Коммуны",
|
||||||
|
:description => ""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
const partners_info = Dict(
|
||||||
|
"en" => Dict(
|
||||||
|
:title => "LibSoc - Partners",
|
||||||
|
:description => ""
|
||||||
|
),
|
||||||
|
"ru" => Dict(
|
||||||
|
:title => "LibSoc - Партнеры",
|
||||||
|
:description => ""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
function get_locale()
|
||||||
|
data = payload()
|
||||||
|
if :locale in keys(data)
|
||||||
|
return data[:locale]
|
||||||
|
else
|
||||||
|
return "en"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
#---Functions---------------------------------------------------------
|
||||||
|
|
||||||
function landing()
|
function landing()
|
||||||
|
locale = get_locale()
|
||||||
html(:basic,:landing, layout = dict_layouts[:landing], context = @__MODULE__,
|
html(:basic,:landing, layout = dict_layouts[:landing], context = @__MODULE__,
|
||||||
title = "LibSoc - A Global Network of Libertarian Socialists",
|
title = landing_info[locale][:title],
|
||||||
description = ""
|
description = landing_info[locale][:description]
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
function manifesto()
|
function manifesto()
|
||||||
|
locale = get_locale()
|
||||||
html(:basic,:manifesto, layout = dict_layouts[:manifesto], context = @__MODULE__,
|
html(:basic,:manifesto, layout = dict_layouts[:manifesto], context = @__MODULE__,
|
||||||
title = "LibSoc - Manifesto",
|
title = manifesto_info[locale][:title],
|
||||||
description = ""
|
description = manifesto_info[locale][:description]
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
function join_us()
|
function join_us()
|
||||||
|
locale = get_locale()
|
||||||
html(:basic,:join_us, layout = dict_layouts[:join_us], context = @__MODULE__,
|
html(:basic,:join_us, layout = dict_layouts[:join_us], context = @__MODULE__,
|
||||||
title = "LibSoc - Join Us",
|
title = join_us_info[locale][:title],
|
||||||
description = ""
|
description = join_us_info[locale][:description]
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
function groups()
|
function groups()
|
||||||
|
locale = get_locale()
|
||||||
html(:basic,:groups, layout = dict_layouts[:groups], context = @__MODULE__,
|
html(:basic,:groups, layout = dict_layouts[:groups], context = @__MODULE__,
|
||||||
title = "LibSoc - Groups",
|
title = groups_info[locale][:title],
|
||||||
description = ""
|
description = groups_info[locale][:description]
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
function cooperatives()
|
function cooperatives()
|
||||||
|
locale = get_locale()
|
||||||
html(:basic,:cooperatives, layout = dict_layouts[:cooperatives], context = @__MODULE__,
|
html(:basic,:cooperatives, layout = dict_layouts[:cooperatives], context = @__MODULE__,
|
||||||
title = "LibSoc - Cooperatives",
|
title = cooperatives_info[locale][:title],
|
||||||
description = ""
|
description = cooperatives_info[locale][:description]
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
function communities()
|
function communities()
|
||||||
|
locale = get_locale()
|
||||||
html(:basic,:communities, layout = dict_layouts[:communities], context = @__MODULE__,
|
html(:basic,:communities, layout = dict_layouts[:communities], context = @__MODULE__,
|
||||||
title = "LibSoc - Communities",
|
title = communities_info[locale][:title],
|
||||||
description = ""
|
description = communities_info[locale][:description]
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
function partners()
|
function partners()
|
||||||
|
locale = get_locale()
|
||||||
html(:basic,:partners, layout = dict_layouts[:partners], context = @__MODULE__,
|
html(:basic,:partners, layout = dict_layouts[:partners], context = @__MODULE__,
|
||||||
title = "LibSoc - Partners",
|
title = partners_info[locale][:title],
|
||||||
description = ""
|
description = partners_info[locale][:description]
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue