mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 20:19:13 +08:00
Merge pull request #4891 from Ultimaker/show_website_as_support_in_marketplace
Show website for support
This commit is contained in:
commit
b1b773e464
@ -36,12 +36,19 @@ Item
|
|||||||
var pg_name = "printingGuidelines"
|
var pg_name = "printingGuidelines"
|
||||||
return (pg_name in packageData.links) ? packageData.links[pg_name] : undefined
|
return (pg_name in packageData.links) ? packageData.links[pg_name] : undefined
|
||||||
}
|
}
|
||||||
|
|
||||||
|
property var materialWebsiteUrl:
|
||||||
|
{
|
||||||
|
var pg_name = "website"
|
||||||
|
return (pg_name in packageData.links) ? packageData.links[pg_name] : undefined
|
||||||
|
}
|
||||||
anchors.topMargin: UM.Theme.getSize("default_margin").height
|
anchors.topMargin: UM.Theme.getSize("default_margin").height
|
||||||
height: visible ? childrenRect.height : 0
|
height: visible ? childrenRect.height : 0
|
||||||
|
|
||||||
visible: packageData.type == "material" &&
|
visible: packageData.type == "material" &&
|
||||||
(packageData.has_configs || technicalDataSheetUrl !== undefined ||
|
(packageData.has_configs || technicalDataSheetUrl !== undefined ||
|
||||||
safetyDataSheetUrl !== undefined || printingGuidelinesUrl !== undefined)
|
safetyDataSheetUrl !== undefined || printingGuidelinesUrl !== undefined ||
|
||||||
|
materialWebsiteUrl !== undefined)
|
||||||
|
|
||||||
Item
|
Item
|
||||||
{
|
{
|
||||||
@ -180,7 +187,8 @@ Item
|
|||||||
anchors.top: combatibilityItem.bottom
|
anchors.top: combatibilityItem.bottom
|
||||||
anchors.topMargin: UM.Theme.getSize("default_margin").height / 2
|
anchors.topMargin: UM.Theme.getSize("default_margin").height / 2
|
||||||
visible: base.technicalDataSheetUrl !== undefined ||
|
visible: base.technicalDataSheetUrl !== undefined ||
|
||||||
base.safetyDataSheetUrl !== undefined || base.printingGuidelinesUrl !== undefined
|
base.safetyDataSheetUrl !== undefined || base.printingGuidelinesUrl !== undefined ||
|
||||||
|
base.materialWebsiteUrl !== undefined
|
||||||
height: visible ? contentHeight : 0
|
height: visible ? contentHeight : 0
|
||||||
text:
|
text:
|
||||||
{
|
{
|
||||||
@ -208,6 +216,16 @@ Item
|
|||||||
var pg_name = catalog.i18nc("@action:label", "Printing Guidelines")
|
var pg_name = catalog.i18nc("@action:label", "Printing Guidelines")
|
||||||
result += "<a href='%1'>%2</a>".arg(base.printingGuidelinesUrl).arg(pg_name)
|
result += "<a href='%1'>%2</a>".arg(base.printingGuidelinesUrl).arg(pg_name)
|
||||||
}
|
}
|
||||||
|
if (base.materialWebsiteUrl !== undefined)
|
||||||
|
{
|
||||||
|
if (result.length > 0)
|
||||||
|
{
|
||||||
|
result += "<br/>"
|
||||||
|
}
|
||||||
|
var pg_name = catalog.i18nc("@action:label", "Website")
|
||||||
|
result += "<a href='%1'>%2</a>".arg(base.materialWebsiteUrl).arg(pg_name)
|
||||||
|
}
|
||||||
|
|
||||||
return result
|
return result
|
||||||
}
|
}
|
||||||
font: UM.Theme.getFont("very_small")
|
font: UM.Theme.getFont("very_small")
|
||||||
|
@ -144,10 +144,6 @@ Item
|
|||||||
{
|
{
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
if (details.author_email)
|
|
||||||
{
|
|
||||||
return "<a href=\"mailto:" + details.author_email+"?Subject=Cura: " + details.name + "\">" + details.author_name + "</a>"
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return "<a href=\"" + details.website + "\">" + details.author_name + "</a>"
|
return "<a href=\"" + details.website + "\">" + details.author_name + "</a>"
|
||||||
|
@ -37,7 +37,7 @@ Item
|
|||||||
anchors.top: packageName.bottom
|
anchors.top: packageName.bottom
|
||||||
width: parent.width
|
width: parent.width
|
||||||
text: model.description
|
text: model.description
|
||||||
maximumLineCount: 6
|
maximumLineCount: 12
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WordWrap
|
||||||
color: UM.Theme.getColor("text")
|
color: UM.Theme.getColor("text")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user