コード例 #1
0
def migrate(ctx):
    """Bug 863474 - Migrate search prompts to fluent, part {index}."""

    ctx.add_transforms(
        "browser/browser/search.ftl", "browser/browser/search.ftl",
        transforms_from("""
opensearch-error-duplicate-title = { COPY(from_path, "error_invalid_engine_title") }
""",
                        from_path="toolkit/chrome/search/search.properties"))

    ctx.add_transforms(
        "browser/browser/search.ftl", "browser/browser/search.ftl", [
            FTL.Message(id=FTL.Identifier("opensearch-error-duplicate-desc"),
                        value=REPLACE(
                            "toolkit/chrome/search/search.properties",
                            "error_duplicate_engine_msg", {
                                "%1$S": TERM_REFERENCE("brand-short-name"),
                                "%2$S": VARIABLE_REFERENCE("location-url"),
                            },
                            normalize_printf=True))
        ])

    ctx.add_transforms(
        "browser/browser/search.ftl", "browser/browser/search.ftl",
        transforms_from("""
opensearch-error-format-title = { COPY(from_path, "error_invalid_format_title") }
""",
                        from_path="toolkit/chrome/search/search.properties"))

    ctx.add_transforms(
        "browser/browser/search.ftl", "browser/browser/search.ftl", [
            FTL.Message(id=FTL.Identifier("opensearch-error-format-desc"),
                        value=REPLACE(
                            "toolkit/chrome/search/search.properties",
                            "error_invalid_engine_msg2", {
                                "%1$S": TERM_REFERENCE("brand-short-name"),
                                "%2$S": VARIABLE_REFERENCE("location-url"),
                            },
                            normalize_printf=True))
        ])

    ctx.add_transforms(
        "browser/browser/search.ftl", "browser/browser/search.ftl",
        transforms_from("""
opensearch-error-download-title = { COPY(from_path, "error_loading_engine_title") }
""",
                        from_path="toolkit/chrome/search/search.properties"))

    ctx.add_transforms(
        "browser/browser/search.ftl", "browser/browser/search.ftl", [
            FTL.Message(id=FTL.Identifier("opensearch-error-download-desc"),
                        value=REPLACE(
                            "toolkit/chrome/search/search.properties",
                            "error_loading_engine_msg2", {
                                "%1$S": TERM_REFERENCE("brand-short-name"),
                                "%2$S": VARIABLE_REFERENCE("location-url"),
                                "\n": FTL.TextElement(" "),
                            },
                            normalize_printf=True))
        ])
コード例 #2
0
ファイル: fast.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/firefox/templates/firefox/features/fast.html, part {index}."""

    ctx.add_transforms(
        "firefox/features/fast.ftl", "firefox/features/fast.ftl",
        transforms_from("""
features-fast-get-more-done-browse-faster = {COPY(fast, "Get more done. Browse faster and lighter with multiple tabs",)}
features-fast-our-new-powerful-multi-process = {COPY(fast, "Our new, powerful multi-process platform handles all your tabs without slowing down your computer.",)}
""",
                        fast=fast) +
        [
            FTL.Message(
                id=FTL.Identifier(
                    "features-fast-firefox-is-now-faster-and-leaner"),
                value=REPLACE(fast, "Firefox is now faster and leaner", {
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                })),
        ] + transforms_from("""
features-fast-weve-been-working-out-so-you = {COPY(fast, "We’ve been working out, so you can get more done.",)}
features-fast-use-less-memory = {COPY(fast, "Use less memory",)}
""",
                            fast=fast) +
        [
            FTL.Message(
                id=FTL.Identifier("features-fast-no-one-likes-a-computer-hog"),
                value=REPLACE(
                    fast,
                    "No one likes a computer hog! Firefox is a lean, mean (actually we’re pretty nice) browsing machine. Since we use less RAM than Chrome, your other programs can keep running at top speed.",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                        "Chrome": TERM_REFERENCE("brand-name-chrome"),
                    })),
        ] + transforms_from("""
features-fast-get-all-the-tabs-without-lags = {COPY(fast, "Get all the tabs without lags",)}
""",
                            fast=fast) +
        [
            FTL.Message(
                id=FTL.Identifier("features-fast-multi-tasking-with-multiple"),
                value=REPLACE(
                    fast,
                    "Multi-tasking with multiple tabs just got easier. Firefox is now a multi-process browser, which means that your tabs stay fresh and won’t take forever to reload. With 86% less hang time, switch quickly between tabs even as you open more.",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ] + transforms_from("""
features-fast-level-up-browser-gameplay = {COPY(fast, "Level-up browser gameplay",)}
""",
                            fast=fast) +
        [
            FTL.Message(
                id=FTL.
                Identifier("features-fast-we-led-the-tech-to-run-3d-games"),
                value=REPLACE(
                    fast,
                    "We led the tech to run 3D games at near-native speeds, and now Firefox is bringing better performance to online gaming. Our powerful browser reduces lags, speeds up ping times and optimizes overall gameplay through faster, leaner browsing.",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ])
コード例 #3
0
ファイル: firstrun.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/firefox/templates/firefox/firstrun/firstrun.html, part {index}."""

    ctx.add_transforms(
        "firefox/firstrun.ftl",
        "firefox/firstrun.ftl",
        transforms_from("""
firstrun-firefox-browser = { -brand-name-firefox-browser }
""", quantum=quantum) + [
            FTL.Message(
                id=FTL.Identifier("firstrun-welcome-to-firefox"),
                value=REPLACE(
                    quantum,
                    "Welcome to Firefox",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    }
                )
            ),
            FTL.Message(
                id=FTL.Identifier("firstrun-take-firefox-with-you"),
                value=REPLACE(
                    quantum,
                    "Take Firefox with You",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    }
                )
            ),
            FTL.Message(
                id=FTL.Identifier("firstrun-already-using-firefox"),
                value=REPLACE(
                    quantum,
                    "Already using Firefox?",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    }
                )
            ),
        ] + transforms_from("""
firstrun-get-your-bookmarks-history = {COPY(quantum, "Get your bookmarks, history, passwords and other settings on all your devices.",)}
""", quantum=quantum) + [
            FTL.Message(
                id=FTL.Identifier("firstrun-sign-in-to-your-account"),
                value=REPLACE(
                    quantum,
                    "Sign in to your account and we’ll sync the bookmarks, passwords and other great things you’ve saved to Firefox on other devices.",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    }
                )
            ),
        ] + transforms_from("""
firstrun-already-have-an-account = {COPY(quantum, "Already have an account?",)}
firstrun-sign-in = {COPY(quantum, "Sign In",)}
""", quantum=quantum)
        )
コード例 #4
0
def migrate(ctx):
    """Bug 1608188 - Migrate blocklist.dtd to Fluent, part {index}."""
    ctx.add_transforms(
        "toolkit/toolkit/extensions/blocklist.ftl",
        "toolkit/toolkit/extensions/blocklist.ftl",
        transforms_from(
            """
blocklist-window =
    .title = { COPY(from_path, "blocklist.title", trim:"True") }
    .style = { COPY(from_path, "blocklist.style", trim:"True") }

blocklist-soft-and-hard = { COPY(from_path, "blocklist.softandhard", trim:"True") }
blocklist-hard-blocked = { COPY(from_path, "blocklist.hardblocked", trim:"True") }
blocklist-soft-blocked = { COPY(from_path, "blocklist.softblocked", trim:"True") }
blocklist-more-information =
    .value = { COPY(from_path, "blocklist.moreinfo", trim:"True") }
blocklist-blocked =
    .label = { COPY(from_path, "blocklist.blocked.label", trim:"True") }
blocklist-checkbox =
    .label = { COPY(from_path, "blocklist.checkbox.label", trim:"True") }
""",
            from_path="toolkit/chrome/mozapps/extensions/blocklist.dtd"))

    ctx.add_transforms(
        "toolkit/toolkit/extensions/blocklist.ftl",
        "toolkit/toolkit/extensions/blocklist.ftl", [
            FTL.Message(
                id=FTL.Identifier("blocklist-accept"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("label"),
                        value=REPLACE(
                            "toolkit/chrome/mozapps/extensions/blocklist.dtd",
                            "blocklist.accept.label",
                            {
                                "&brandShortName;":
                                TERM_REFERENCE("brand-short-name")
                            },
                            trim=True,
                        )),
                    FTL.Attribute(
                        id=FTL.Identifier("accesskey"),
                        value=COPY(
                            "toolkit/chrome/mozapps/extensions/blocklist.dtd",
                            "blocklist.accept.accesskey",
                            trim=True,
                        )),
                ]),
            FTL.Message(
                id=FTL.Identifier("blocklist-label-summary"),
                value=REPLACE(
                    "toolkit/chrome/mozapps/extensions/blocklist.dtd",
                    "blocklist.summary",
                    {"&brandShortName;": TERM_REFERENCE("brand-short-name")},
                    trim=True,
                )),
        ])
コード例 #5
0
def migrate(ctx):
    """Bug 1523736 - Migrate updates.dtd to Fluent, part {index}."""
    ctx.add_transforms(
        "toolkit/toolkit/updates/elevation.ftl",
        "toolkit/toolkit/updates/elevation.ftl",
    transforms_from(
"""
elevation-update-wizard =
    .title = { COPY(from_path, "updateWizard.title") }
elevation-details-link-label =
    .value = { COPY(from_path, "details.link") }
elevation-finished-page = { COPY(from_path, "finishedPage.title") }
elevation-finished-background = { COPY(from_path, "finishedBackground.name") }
""",from_path="toolkit/chrome/mozapps/update/updates.dtd"))

    ctx.add_transforms(
        "toolkit/toolkit/updates/elevation.ftl",
        "toolkit/toolkit/updates/elevation.ftl",
        [
            FTL.Message(
                id = FTL.Identifier("elevation-error-manual"),
                value = REPLACE(
                    "toolkit/chrome/mozapps/update/updates.dtd",
                    "errorManual.label",
                    {
                        "&brandShortName;": TERM_REFERENCE("brand-short-name")
                    },
                    trim = True
                )
            ),
            FTL.Message(
                id = FTL.Identifier("elevation-finished-background-page"),
                value = REPLACE(
                    "toolkit/chrome/mozapps/update/updates.dtd",
                    "finishedBackgroundPage.text",
                    {
                        "&brandShortName;": TERM_REFERENCE("brand-short-name")
                    },
                    trim = True
                )
            ),
            FTL.Message(
                id = FTL.Identifier("elevation-more-elevated"),
                value = REPLACE(
                    "toolkit/chrome/mozapps/update/updates.dtd",
                    "finishedBackground.moreElevated",
                    {
                        "&brandShortName;": TERM_REFERENCE("brand-short-name")
                    },
                    trim = True
                )
            ),

        ]
    )
コード例 #6
0
ファイル: page3.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/firefox/templates/firefox/welcome/page3.html, part {index}."""

    ctx.add_transforms("firefox/welcome/page3.ftl", "firefox/welcome/page3.ftl", [
        FTL.Message(
            id=FTL.Identifier("welcome-page3-get-the-free-account-that"),
            value=REPLACE(
                page3,
                "Get the free account that protects your privacy. Join Firefox.",
                {
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                })),
    ] + transforms_from(
        """
welcome-page3-no-account-required-but-you = {COPY(page3, "No account required. But you might want one.",)}
""",
        page3=page3
    ) + [
        FTL.Message(
            id=FTL.Identifier("welcome-page3-the-firefox-browser-collects"),
            value=REPLACE(
                page3,
                "The Firefox browser collects so little data about you, we don’t even require your email address. But when you use it to create a Firefox account, we can protect your privacy across more of your online life.",
                {
                    "Firefox":
                    TERM_REFERENCE("brand-name-firefox"),
                    "Firefox account":
                    TERM_REFERENCE("brand-name-firefox-account"),
                })),
    ] + transforms_from(
        """
welcome-page3-firefox-monitor = { -brand-name-firefox-monitor }
welcome-page3-have-at-least-one-company = {COPY(page3, "Have at least one company looking out for your data, instead of leaking it.",)}
welcome-page3-firefox-lockwise = { -brand-name-firefox-lockwise }
welcome-page3-never-forget-reset-or-travel = {COPY(page3, "Never forget, reset or travel without your passwords again.",)}
welcome-page3-facebook-container = { -brand-name-facebook-container }
""",
        page3=page3
    ) + [
        FTL.Message(
            id=FTL.Identifier(
                "welcome-page3-get-a-container-to-keep-facebook"),
            value=REPLACE(
                page3,
                "Get a container to keep Facebook out of your business.", {
                    "Facebook": TERM_REFERENCE("brand-name-facebook"),
                })),
    ] + transforms_from("""
welcome-page3-pocket = { -brand-name-pocket }
welcome-page3-trade-clickbait-and-fake-news = {COPY(page3, "Trade clickbait and fake news for quality content.",)}
welcome-page3-firefox-send = { -brand-name-firefox-send }
welcome-page3-send-huge-files-to-anyone = {COPY(page3, "Send huge files to anyone you want, with self-destructing links.",)}
welcome-page3-why-am-i-seeing-this = {COPY(page3, "Why am I seeing this?",)}
""",
                        page3=page3))
コード例 #7
0
def migrate(ctx):
    """Bug 1668284 - Unknown content type change settings label is no longer accurate, part {index}."""

    ctx.add_transforms(
        "toolkit/toolkit/global/unknownContentType.ftl",
        "toolkit/toolkit/global/unknownContentType.ftl",
        [
            FTL.Message(
                id=FTL.Identifier("unknowncontenttype-settingschange"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("value"),
                        value=FTL.Pattern(
                            elements=[
                                FTL.Placeable(
                                    expression=FTL.SelectExpression(
                                        selector=MESSAGE_REFERENCE("PLATFORM()"),
                                        variants=[
                                            FTL.Variant(
                                                key=FTL.Identifier("windows"),
                                                default=False,
                                                value=REPLACE(
                                                    "toolkit/chrome/mozapps/downloads/settingsChange.dtd",
                                                    "settingsChangeOptions.label",
                                                    {
                                                        "&brandShortName;": TERM_REFERENCE(
                                                            "brand-short-name"
                                                        ),
                                                    },
                                                ),
                                            ),
                                            FTL.Variant(
                                                key=FTL.Identifier("other"),
                                                default=True,
                                                value=REPLACE(
                                                    "toolkit/chrome/mozapps/downloads/settingsChange.dtd",
                                                    "settingsChangePreferences.label",
                                                    {
                                                        "&brandShortName;": TERM_REFERENCE(
                                                            "brand-short-name"
                                                        ),
                                                    },
                                                ),
                                            ),
                                        ],
                                    )
                                )
                            ]
                        ),
                    )
                ],
            )
        ],
    )
コード例 #8
0
def migrate(ctx):
    """Bug 1517307 - Convert resetProfile.dtd to Fluent, part {index}."""

    ctx.add_transforms(
        "toolkit/toolkit/global/resetProfile.ftl",
        "toolkit/toolkit/global/resetProfile.ftl",
        transforms_from("""
refresh-profile-description = { COPY("toolkit/chrome/global/resetProfile.dtd","refreshProfile.dialog.description1") }
refresh-profile-description-details = { COPY("toolkit/chrome/global/resetProfile.dtd","refreshProfile.dialog.description2") }
refresh-profile-remove = { COPY("toolkit/chrome/global/resetProfile.dtd","refreshProfile.dialog.items.label1") }
refresh-profile-restore = { COPY("toolkit/chrome/global/resetProfile.dtd","refreshProfile.dialog.items.label2") }
"""))
    ctx.add_transforms(
        "toolkit/toolkit/global/resetProfile.ftl",
        "toolkit/toolkit/global/resetProfile.ftl", [
            FTL.Message(id=FTL.Identifier("refresh-profile-dialog"),
                        attributes=[
                            FTL.Attribute(
                                FTL.Identifier("title"),
                                value=REPLACE(
                                    "toolkit/chrome/global/resetProfile.dtd",
                                    "refreshProfile.dialog.title", {
                                        "&brandShortName;":
                                        TERM_REFERENCE("brand-short-name")
                                    }))
                        ]),
            FTL.Message(id=FTL.Identifier("refresh-profile-dialog-button"),
                        attributes=[
                            FTL.Attribute(
                                FTL.Identifier("label"),
                                value=REPLACE(
                                    "toolkit/chrome/global/resetProfile.dtd",
                                    "refreshProfile.dialog.button.label", {
                                        "&brandShortName;":
                                        TERM_REFERENCE("brand-short-name")
                                    }))
                        ]),
            FTL.Message(
                id=FTL.Identifier("refresh-profile"),
                value=REPLACE(
                    "toolkit/chrome/global/resetProfile.dtd",
                    "refreshProfile.title",
                    {"&brandShortName;": TERM_REFERENCE("brand-short-name")})),
            FTL.Message(
                id=FTL.Identifier("refresh-profile-button"),
                value=REPLACE(
                    "toolkit/chrome/global/resetProfile.dtd",
                    "refreshProfile.button.label",
                    {"&brandShortName;": TERM_REFERENCE("brand-short-name")})),
        ])
コード例 #9
0
ファイル: 404.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/base/templates/404.html, part {index}."""

    ctx.add_transforms(
        "404.ftl", "404.ftl",
        transforms_from("""
not-found-page-not-found-page-page-not-found = {COPY(not_found, "404: Page Not Found",)}
not-found-page-sorry-we-cant-find-that-page = {COPY(not_found, "Sorry, we can’t find that page",)}
not-found-page-were-all-about-a-healthy-internet = {COPY(not_found, "We’re all about a healthy internet but sometimes broken URLs happen.",)}
not-found-page-go-back = {COPY(not_found, "Go Back",)}
""",
                        not_found=not_found) +
        [
            FTL.Message(
                id=FTL.Identifier(
                    "not-found-page-learn-about-mozilla-the-non"),
                value=REPLACE(
                    not_found,
                    "<a href=\"%(about)s\">Learn</a> about Mozilla, the non-profit behind Firefox.",
                    {
                        "%%": "%",
                        "%(about)s": VARIABLE_REFERENCE("about"),
                        "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
            FTL.Message(
                id=FTL.Identifier(
                    "not-found-page-explore-the-entire-family-for"),
                value=REPLACE(
                    not_found,
                    "<a href=%(explore)s>Explore</a> the entire family for Firefox products designed to respect your privacy.",
                    {
                        "%%": "%",
                        "%(explore)s": VARIABLE_REFERENCE("explore"),
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
            FTL.Message(
                id=FTL.Identifier(
                    "not-found-page-download-the-firefox-browser"),
                value=REPLACE(
                    not_found,
                    "<a href=%(download)s>Download</a> the Firefox browser for your mobile device or desktop",
                    {
                        "%%": "%",
                        "%(download)s": VARIABLE_REFERENCE("download"),
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ])
コード例 #10
0
ファイル: opt-out-confirmation.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/newsletter/templates/newsletter/opt-out-confirmation.html, part {index}."""

    ctx.add_transforms(
        "newsletter/opt-out-confirmation.ftl",
        "newsletter/opt-out-confirmation.ftl",
        transforms_from("""
opt-out-confirmation-cool-we-hear = {COPY(opt_out_confirmation, "Cool. We hear you.",)}
opt-out-confirmation-youre-now-opted = {COPY(opt_out_confirmation, "You’re now opted out of a series of emails about setting up your account.",)}
opt-out-confirmation-youll-continue = {COPY(opt_out_confirmation, "You’ll continue to receive other emails you’re subscribed to, along with occasional important updates about your account. To manage all your subscriptions, enter your email below — we need to make sure we’re talking to the right person.",)}
opt-out-confirmation-your-email = {COPY(opt_out_confirmation, "Your email address:",)}
opt-out-confirmation-yournameexamplecom = {COPY(opt_out_confirmation, "*****@*****.**",)}
opt-out-confirmation-manage-preferences = {COPY(opt_out_confirmation, "Manage Preferences",)}
opt-out-confirmation-prefer-to-get = {COPY(opt_out_confirmation, "Prefer to get information another way?",)}
opt-out-confirmation-check-out-our = {COPY(opt_out_confirmation, "Check out our blogs",)}
opt-out-confirmation-get-help = {COPY(opt_out_confirmation, "Get help",)}
""",
                        opt_out_confirmation=opt_out_confirmation) +
        [
            FTL.Message(
                id=FTL.Identifier("opt-out-confirmation-subscribe-to"),
                value=REPLACE(
                    opt_out_confirmation,
                    "Subscribe to occasional newsletter updates from Firefox",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ])
コード例 #11
0
def migrate(ctx):
    """Migrate bedrock/base/templates/macros.html, part {index}."""

    ctx.add_transforms("fxa_form.ftl", "fxa_form.ftl", [
        FTL.Message(
            id=FTL.Identifier("fxa-form-enter-your-email"),
            value=REPLACE(
                "main.lang",
                "<strong>Enter your email</strong> to access Firefox Accounts.",
                {
                    "Firefox Accounts":
                    TERM_REFERENCE("brand-name-firefox-accounts"),
                })),
        FTL.Message(
            id=FTL.Identifier("fxa-form-by-proceeding"),
            value=REPLACE(
                "main.lang",
                "By proceeding, you agree to the <a href=\"%(url1)s\">Terms of Service</a> and <a href=\"%(url2)s\">Privacy Notice</a>.",
                {
                    "%%": "%",
                    "%(url1)s": VARIABLE_REFERENCE("url1"),
                    "%(url2)s": VARIABLE_REFERENCE("url2"),
                })),
    ])

    ctx.add_transforms(
        "fxa_form.ftl", "fxa_form.ftl",
        transforms_from("""
fxa-form-email-address = {COPY(main, "Email address",)}
fxa-form-continue = {COPY(main, "Continue",)}
fxa-form-create-account = {COPY(main, "Create account",)}
fxa-form-get-the-app = {COPY(main, "Get the app",)}
""",
                        main=main))
コード例 #12
0
def migrate(ctx):
    """Migrate bedrock/privacy/templates/privacy/principles.html, part {index}."""

    ctx.add_transforms(
        "privacy/principles.ftl", "privacy/principles.ftl",
        transforms_from("""
privacy-principles-data-privacy-principles = {COPY(principles, "Data Privacy Principles",)}
""",
                        principles=principles) +
        [
            FTL.Message(
                id=FTL.Identifier(
                    "privacy-principles-mozilla-is-an-open-source"),
                value=REPLACE(
                    principles,
                    "Mozilla is an open source project with a mission to improve your Internet experience. This is a driving force behind our privacy practices.",
                    {
                        "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                    })),
            FTL.Message(
                id=FTL.Identifier(
                    "privacy-principles-the-following-five-principles"),
                value=REPLACE(
                    principles,
                    "The following five principles stem from the <a href=\"%(link)s\">Mozilla Manifesto</a> and inform how we:",
                    {
                        "%%": "%",
                        "%(link)s": VARIABLE_REFERENCE("link"),
                        "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                    })),
        ] + transforms_from("""
privacy-principles-develop-our-products = {COPY(principles, "develop our products and services",)}
privacy-principles-manage-user-data-we-collect = {COPY(principles, "manage user data we collect",)}
privacy-principles-select-and-interact-with = {COPY(principles, "select and interact with partners",)}
privacy-principles-shape-our-public-policy = {COPY(principles, "shape our public policy and advocacy work",)}
privacy-principles-no-surprises = {COPY(principles, "No surprises",)}
privacy-principles-use-and-share-information = {COPY(principles, "Use and share information in a way that is transparent and benefits the user.",)}
privacy-principles-user-control = {COPY(principles, "User control",)}
privacy-principles-develop-products-and = {COPY(principles, "Develop products and advocate for best practices that put users in control of their data and online experiences.",)}
privacy-principles-limited-data = {COPY(principles, "Limited data",)}
privacy-principles-collect-what-we-need = {COPY(principles, "Collect what we need, de-identify where we can and delete when no longer necessary.",)}
privacy-principles-sensible-settings = {COPY(principles, "Sensible settings",)}
privacy-principles-design-for-a-thoughtful = {COPY(principles, "Design for a thoughtful balance of safety and user experience.",)}
privacy-principles-defense-in-depth = {COPY(principles, "Defense in depth",)}
privacy-principles-maintain-multi-layered = {COPY(principles, "Maintain multi-layered security controls and practices, many of which are publicly verifiable.",)}
""",
                            principles=principles))
コード例 #13
0
def migrate(ctx):
    """Bug 1731381  - Migrate profileSelection conflict message from properties to Fluent, part {index}."""
    ctx.add_transforms(
        "toolkit/toolkit/global/profileSelection.ftl",
        "toolkit/toolkit/global/profileSelection.ftl",
        [
            FTL.Message(
                id=FTL.Identifier("profile-selection-conflict-message"),
                value=REPLACE(
                    "toolkit/chrome/mozapps/profile/profileSelection.properties",
                    "conflictMessage",
                    {
                        "%1$S": TERM_REFERENCE("brand-product-name"),
                        "%2$S": TERM_REFERENCE("brand-short-name"),
                    },
                ),
            ),
        ],
    )
コード例 #14
0
def migrate(ctx):
    """Bug 1622269 - Migrate cert error titles from netError.dtd to aboutCertError.ftl, part {index}"""
    ctx.add_transforms(
        "browser/browser/aboutCertError.ftl",
        "browser/browser/aboutCertError.ftl",
        transforms_from("""
generic-title = { COPY(from_path, "generic.title") }
captivePortal-title = { COPY(from_path, "captivePortal.title") }
dnsNotFound-title = { COPY(from_path, "dnsNotFound.title1") }
fileNotFound-title = { COPY(from_path, "fileNotFound.title") }
fileAccessDenied-title = { COPY(from_path, "fileAccessDenied.title") }
malformedURI-title = { COPY(from_path, "malformedURI.title1") }
unknownProtocolFound-title = { COPY(from_path, "unknownProtocolFound.title") }
connectionFailure-title = { COPY(from_path, "connectionFailure.title") }
netTimeout-title = { COPY(from_path, "netTimeout.title") }
redirectLoop-title = { COPY(from_path, "redirectLoop.title") }
unknownSocketType-title = { COPY(from_path, "unknownSocketType.title") }
netReset-title = { COPY(from_path, "netReset.title") }
notCached-title = { COPY(from_path, "notCached.title") }
netOffline-title = { COPY(from_path, "netOffline.title") }
netInterrupt-title = { COPY(from_path, "netInterrupt.title") }
deniedPortAccess-title = { COPY(from_path, "deniedPortAccess.title") }
proxyResolveFailure-title = { COPY(from_path, "proxyResolveFailure.title") }
proxyConnectFailure-title = { COPY(from_path, "proxyConnectFailure.title") }
contentEncodingError-title = { COPY(from_path, "contentEncodingError.title") }
unsafeContentType-title = { COPY(from_path, "unsafeContentType.title") }
nssFailure2-title = { COPY(from_path, "nssFailure2.title") }
nssBadCert-title = { COPY(from_path, "certerror.longpagetitle2") }
nssBadCert-sts-title = { COPY(from_path, "certerror.sts.longpagetitle") }
cspBlocked-title = { COPY(from_path, "cspBlocked.title") }
xfoBlocked-title = { COPY(from_path, "xfoBlocked.title") }
remoteXUL-title = { COPY(from_path, "remoteXUL.title") }
corruptedContentError-title = { COPY(from_path, "corruptedContentErrorv2.title") }
sslv3Used-title = { COPY(from_path, "sslv3Used.title") }
inadequateSecurityError-title = { COPY(from_path, "inadequateSecurityError.title") }
blockedByPolicy-title = { COPY(from_path, "blockedByPolicy.title") }
clockSkewError-title = { COPY(from_path, "clockSkewError.title") }
networkProtocolError-title = { COPY(from_path, "networkProtocolError.title") }
""",
                        from_path="browser/chrome/overrides/netError.dtd"))
    ctx.add_transforms(
        "browser/browser/aboutCertError.ftl",
        "browser/browser/aboutCertError.ftl", [
            FTL.Message(
                id=FTL.Identifier("certerror-mitm-title"),
                value=REPLACE(
                    "browser/chrome/overrides/netError.dtd",
                    "certerror.mitm.title",
                    {
                        "&brandShortName;": TERM_REFERENCE("brand-short-name"),
                    },
                ),
            ),
        ])
コード例 #15
0
def migrate(ctx):
    """Bug 1521792 - Migrate unknownContentType dialog to FTL, part {index}"""

    ctx.add_transforms(
        "toolkit/toolkit/global/unknownContentType.ftl",
        "toolkit/toolkit/global/unknownContentType.ftl",
        transforms_from(
            """

unknowncontenttype-intro = { COPY(path1, "intro2.label") }
unknowncontenttype-which-is = { COPY(path1, "whichIs.label") }
unknowncontenttype-from = { COPY(path1, "from.label") }
unknowncontenttype-prompt = { COPY(path1, "unknownPromptText.label") }
""",
            path1="toolkit/chrome/mozapps/downloads/unknownContentType.dtd",
        ) + [
            FTL.Message(
                id=FTL.Identifier("unknowncontenttype-action-question"),
                value=REPLACE(
                    "toolkit/chrome/mozapps/downloads/unknownContentType.dtd",
                    "actionQuestion.label",
                    {
                        "&brandShortName;": TERM_REFERENCE("brand-short-name"),
                    },
                ),
            ),
        ] + transforms_from(
            """
unknowncontenttype-open-with =
    .label = { COPY(path1, "openWith.label") }
    .accesskey = { COPY(path1, "openWith.accesskey") }
unknowncontenttype-other =
    .label = { COPY(path1, "other.label") }
unknowncontenttype-choose-handler =
    .label =
        { PLATFORM() ->
            [macos] { COPY(path1, "chooseHandlerMac.label") }
           *[other] { COPY(path1, "chooseHandler.label") }
        }
    .accesskey =
        { PLATFORM() ->
            [macos] { COPY(path1, "chooseHandlerMac.accesskey") }
           *[other] { COPY(path1, "chooseHandler.accesskey") }
        }
unknowncontenttype-save-file =
    .label = { COPY(path1, "saveFile.label") }
    .accesskey = { COPY(path1, "saveFile.accesskey") }
unknowncontenttype-remember-choice =
    .label = { COPY(path1, "rememberChoice.label") }
    .accesskey = { COPY(path1, "rememberChoice.accesskey") }
""",
            path1="toolkit/chrome/mozapps/downloads/unknownContentType.dtd",
        ),
    )
コード例 #16
0
def migrate(ctx):
    """Bug 1732151 - Convert dataReportingNotification to Fluent, part {index}."""

    source = "browser/chrome/browser/browser.properties"
    target = "browser/browser/browser.ftl"
    ctx.add_transforms(
        target,
        target,
        [
            FTL.Message(
                id=FTL.Identifier("data-reporting-notification-message"),
                value=REPLACE(
                    source,
                    "dataReportingNotification.message",
                    {
                        "%1$S": TERM_REFERENCE("brand-short-name"),
                        "%2$S": TERM_REFERENCE("vendor-short-name"),
                    },
                ),
            ),
            FTL.Message(
                id=FTL.Identifier("data-reporting-notification-button"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("label"),
                        value=COPY(source,
                                   "dataReportingNotification.button.label"),
                    ),
                    FTL.Attribute(
                        id=FTL.Identifier("accesskey"),
                        value=COPY(
                            source,
                            "dataReportingNotification.button.accessKey"),
                    ),
                ],
            ),
        ],
    )
コード例 #17
0
ファイル: community-hotline.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/mozorg/templates/mozorg/about/governance/policies/community-hotline.html, part {index}."""

    ctx.add_transforms(
        "mozorg/about/governance/policies/community-hotline.ftl",
        "mozorg/about/governance/policies/community-hotline.ftl",
        transforms_from("""
community-hotline-community-participation = {COPY(community_hotline, "Community Participation Guidelines - How to Report",)}
community-hotline-community-participation = {COPY(community_hotline, "Community Participation Guidelines Hotline",)}
""", community_hotline=community_hotline) + [
            FTL.Message(
                id=FTL.Identifier("community-hotline-the-heart-of-mozilla"),
                value=REPLACE(
                    community_hotline,
                    "The heart of Mozilla is people. We put people first and do our best to recognize, appreciate and respect the diversity of our global contributors. The Mozilla Project welcomes contributions from everyone who shares our goals and wants to contribute in a healthy and constructive manner within our community.",
                    {
                        "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                    }
                )
            ),
            FTL.Message(
                id=FTL.Identifier("community-hotline-to-report-violations"),
                value=REPLACE(
                    community_hotline,
                    "To report violations of the Community Participation Guidelines <strong>in Mozilla’s communities</strong>, please click the “Report” button below. For more information on how to take and give a report, please read “<a href=\"%(howto)s\">How to Report</a>”.",
                    {
                        "%%": "%",
                        "%(howto)s": VARIABLE_REFERENCE("howto"),
                        "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                    }
                )
            ),
        ] + transforms_from("""
community-hotline-report = {COPY(community_hotline, "Report",)}
""", community_hotline=community_hotline)
        )
コード例 #18
0
def migrate(ctx):
    """Bug 1728460  - Migrate appmenu-viewcache.inc.xhtml to Fluent, part {index}."""
    ctx.add_transforms(
        "browser/browser/appmenu.ftl",
        "browser/browser/appmenu.ftl",
        transforms_from(
            """
appmenuitem-print =
    .label = { COPY(from_path, "printCmd.label") }
appmenuitem-downloads =
    .label = { COPY(from_path, "libraryDownloads.label") }
appmenuitem-history =
    .label = { COPY(from_path, "historyMenu.label") }
appmenuitem-zoom =
    .value = { COPY(from_path, "fullZoom.label") }
""",
            from_path="browser/chrome/browser/browser.dtd",
        ),
    )
    ctx.add_transforms(
        "browser/browser/sync.ftl",
        "browser/browser/sync.ftl",
        transforms_from(
            """
fxa-menu-send-tab-to-device-description = { COPY(from_path, "fxa.service.sendTab.description") }
fxa-menu-send-tab-to-device-syncnotready =
    .label = { COPY(from_path, "sendToDevice.syncNotReady.label") }
""",
            from_path="browser/chrome/browser/browser.dtd",
        ),
    )
    ctx.add_transforms(
        "browser/browser/appmenu.ftl",
        "browser/browser/appmenu.ftl",
        [
            FTL.Message(
                id=FTL.Identifier("appmenuitem-fxa-sign-in"),
                value=REPLACE(
                    "browser/chrome/browser/browser.dtd",
                    "fxa.menu.signin.label",
                    {
                        "&brandProductName;":
                        TERM_REFERENCE("brand-product-name"),
                    },
                ),
            ),
        ],
    )
コード例 #19
0
def migrate(ctx):
    """Bug 1695707 - Migrate the DRM panel message to Fluent, part {index}"""
    ctx.add_transforms(
        "browser/browser/browser.ftl",
        "browser/browser/browser.ftl",
        [
            FTL.Message(
                id=FTL.Identifier("eme-notifications-drm-content-playing"),
                value=REPLACE(
                    "browser/chrome/browser/browser.properties",
                    "emeNotifications.drmContentPlaying.message2",
                    {
                        "%1$S": TERM_REFERENCE("brand-short-name"),
                    },
                    normalize_printf=True,
                ),
            ),
        ],
    )
コード例 #20
0
def migrate(ctx):
    """Migrate bedrock/base/templates/macros.html, part {index}."""

    ctx.add_transforms(
        "send_to_device.ftl",
        "send_to_device.ftl",
        [

            FTL.Message(
                id=FTL.Identifier("send-to-device-send-firefox"),
                value=REPLACE(
                    "firefox/sendto.lang",
                    "Send Firefox to your smartphone or tablet",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    }
                )
            ),
        ]
    )

    ctx.add_transforms(
        "send_to_device.ftl",
        "send_to_device.ftl",
        transforms_from("""
send-to-device-your-download-link = {COPY(send_to, "Your download link was sent.",)}
send-to-device-sorry-we-cant-send = {COPY(send_to, "Sorry, we can’t send SMS messages to this phone number.",)}
send-to-device-sorry-this-number = {COPY(send_to, "Sorry. This number isn’t valid. Please enter a U.S. phone number.",)}
send-to-device-please-enter-an-email = {COPY(send_to, "Please enter an email address.",)}
send-to-device-an-error-occured = {COPY(send_to, "An error occurred in our system. Please try again later.",)}
send-to-device-enter-your-email = {COPY(send_to, "Enter your email",)}
send-to-device-enter-your-email-or-phone = {COPY(send_to, "Enter your email or phone number",)}
send-to-device-enter-your-email-or-phone-10-digit = {COPY(send_to, "Enter your email or 10-digit phone number",)}
send-to-device-send = {COPY(send_to, "Send",)}
send-to-device-sms-service-available-in-select = {COPY(send_to, "SMS service available in select countries only. SMS &amp; data rates may apply.",)}
send-to-device-sms-service-available-to-us = {COPY(send_to, "SMS service available to U.S. phone numbers only. SMS &amp; data rates may apply.",)}
send-to-device-intended-recipient-email-sms = {COPY(send_to, "The intended recipient of the email or SMS must have consented.",)}
send-to-device-intended-recipient-email = {COPY(send_to, "The intended recipient of the email must have consented.",)}
send-to-device-check-your-device-email-sms = {COPY(send_to, "Check your device for the email or text message!",)}
send-to-device-check-your-device-email = {COPY(send_to, "Check your device for the email!",)}
send-to-device-send-to-another= {COPY(send_to, "Send to another device",)}
""", send_to=send_to)
        )
コード例 #21
0
def migrate(ctx):
    """Bug 1502396 - Convert change and remove master password dialogs in about:preferences to use Fluent"""

    ctx.add_transforms(
        "toolkit/toolkit/preferences/preferences.ftl",
        "toolkit/toolkit/preferences/preferences.ftl",
        transforms_from(
            """
set-password =
    .title = { COPY(from_path, "setPassword.title") }
set-password-old-password = { COPY(from_path, "setPassword.oldPassword.label") }
set-password-new-password = { COPY(from_path, "setPassword.newPassword.label") }
set-password-reenter-password = { COPY(from_path, "setPassword.reenterPassword.label") }
set-password-meter = { COPY(from_path, "setPassword.meter.label") }
set-password-meter-loading = { COPY(from_path, "setPassword.meter.loading") }
master-password-warning = { COPY(from_path, "masterPasswordWarning.label") }
""",
            from_path="toolkit/chrome/mozapps/preferences/changemp.dtd") +
        [
            FTL.Message(
                id=FTL.Identifier("master-password-description"),
                value=REPLACE(
                    "toolkit/chrome/mozapps/preferences/changemp.dtd",
                    "masterPasswordDescription.label",
                    {"&brandShortName;": TERM_REFERENCE("-brand-short-name")},
                    trim=True)),
        ])

    ctx.add_transforms(
        "toolkit/toolkit/preferences/preferences.ftl",
        "toolkit/toolkit/preferences/preferences.ftl",
        transforms_from(
            """
remove-password =
    .title = { COPY(from_path, "removePassword.title") }
remove-info =
    .value = { COPY(from_path, "removeInfo.label") }
remove-warning1 = { COPY(from_path, "removeWarning1.label") }
remove-warning2 = { COPY(from_path, "removeWarning2.label") }
remove-password-old-password =
    .value = { COPY(from_path, "setPassword.oldPassword.label") }
""",
            from_path="toolkit/chrome/mozapps/preferences/removemp.dtd"))
コード例 #22
0
def migrate(ctx):
    """Bug 1631122 - Convert URL bar dtd strings in browser.xhtml to Fluent, part {index}."""

    ctx.add_transforms(
        "browser/browser/browser.ftl", "browser/browser/browser.ftl",
        transforms_from("""
urlbar-default-placeholder =
    .defaultPlaceholder = { COPY(from_path, "urlbar.placeholder2") }
urlbar-placeholder =
    .placeholder = { COPY(from_path, "urlbar.placeholder2") }
urlbar-remote-control-notification-anchor =
    .tooltiptext = { COPY(from_path, "urlbar.remoteControlNotificationAnchor.tooltip") }
urlbar-permissions-granted =
    .tooltiptext = { COPY(from_path, "urlbar.permissionsGranted.tooltip") }
urlbar-switch-to-tab =
    .value = { COPY(from_path, "urlbar.switchToTab.label") }
urlbar-extension =
    .value = { COPY(from_path, "urlbar.extension.label") }
urlbar-go-end-cap =
    .tooltiptext = { COPY(from_path, "goEndCap.tooltip") }
urlbar-page-action-button =
    .tooltiptext = { COPY(from_path, "pageActionButton.tooltip") }
""",
                        from_path="browser/chrome/browser/browser.dtd"))

    ctx.add_transforms(
        "browser/browser/browser.ftl", "browser/browser/browser.ftl", [
            FTL.Message(
                id=FTL.Identifier("urlbar-pocket-button"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("tooltiptext"),
                        value=REPLACE(
                            "browser/chrome/browser/browser.dtd",
                            "pocketButton.tooltiptext", {
                                "Pocket": TERM_REFERENCE("pocket-brand-name"),
                            })),
                ]),
        ])
コード例 #23
0
ファイル: shared.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/mozorg/templates/mozorg/about/manifesto.html, part {index}."""

    ctx.add_transforms("mozorg/about/shared.ftl", "mozorg/about/shared.ftl", [
        FTL.Message(id=FTL.Identifier("about-shared-about-mozilla"),
                    value=REPLACE(
                        main, "About Mozilla", {
                            "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                        })),
    ] + transforms_from("""
about-shared-mission = {COPY(main, "Mission",)}
about-shared-history = {COPY(main, "History",)}
about-shared-leadership = {COPY(main, "Leadership",)}
about-shared-governance = {COPY(main, "Governance",)}
about-shared-forums = {COPY(main, "Forums",)}
about-shared-patents = {COPY(main, "Patents",)}
about-shared-our-products = {COPY(main, "Our Products",)}
about-shared-software-innovations = {COPY(main, "Software and other innovations designed to advance our mission.",)}
about-shared-get-involved = {COPY(main, "Get Involved",)}
about-shared-volunteer = {COPY(main, "Become a volunteer contributor in a number of different areas.",)}
""",
                        main=main))
コード例 #24
0
def migrate(ctx):
    """Migrate bedrock/firefox/templates/firefox/whatsnew/index.html, part {index}."""

    ctx.add_transforms(
        "firefox/whatsnew/whatsnew-s2d.ftl",
        "firefox/whatsnew/whatsnew-s2d.ftl", [
            FTL.Message(
                id=FTL.Identifier("whatsnew-s2d-download-firefox-for-android"),
                value=REPLACE(
                    whatsnew, "Download Firefox for Android and iOS", {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                        "Android": TERM_REFERENCE("brand-name-android"),
                        "iOS": TERM_REFERENCE("brand-name-ios"),
                    })),
        ] + transforms_from("""
whatsnew-s2d-want-privacy-on-every-device = {COPY(whatsnew, "Want privacy on every device?",)}
""",
                            whatsnew=whatsnew) +
        [
            FTL.Message(
                id=FTL.Identifier("whatsnew-s2d-you-got-it-get-firefox-for"),
                value=REPLACE(
                    whatsnew,
                    "You got it. Get Firefox for mobile.", {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
            FTL.Message(
                id=FTL.Identifier("whatsnew-s2d-send-firefox-to-your-phone"),
                value=REPLACE(
                    whatsnew,
                    "Send Firefox to your phone<br> and unleash your Internet.",
                    {"Firefox": TERM_REFERENCE("brand-name-firefox")})),
            FTL.Message(
                id=FTL.Identifier("whatsnew-s2d-download-firefox-for-your"),
                value=REPLACE(
                    whatsnew,
                    "Download Firefox for your smartphone and tablet.", {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ])
コード例 #25
0
def migrate(ctx):
    """Migrate bedrock/firefox/templates/firefox/facebookcontainer/index.html, part {index}."""

    ctx.add_transforms("firefox/facebook_container.ftl", "firefox/facebook_container.ftl", [
        FTL.Message(
            id=FTL.Identifier(
                "facebook-container-facebook-container-for-firefox"),
            value=REPLACE(
                index,
                "Facebook Container for Firefox | Prevent Facebook from seeing what websites you visit.",
                {
                    "Facebook":
                    TERM_REFERENCE("brand-name-facebook"),
                    "Facebook Container":
                    TERM_REFERENCE("brand-name-facebook-container"),
                    "Firefox":
                    TERM_REFERENCE("brand-name-firefox"),
                })),
        FTL.
        Message(
            id=FTL.Identifier("facebook-container-millions-of-people-around"),
            value=REPLACE(
                index,
                "Millions of people around the world trust Firefox Web browsers on Android, iOS and desktop computers. Fast. Private. Download now!",
                {
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    "Android": TERM_REFERENCE("brand-name-android"),
                    "iOS": TERM_REFERENCE("brand-name-ios"),
                })),
        FTL.
        Message(
            id=FTL.Identifier("facebook-container-facebook-well-contained-keep"
                              ),
            value=REPLACE(
                index,
                "Facebook. Well contained. Keep the rest of your life to yourself.",
                {
                    "Facebook": TERM_REFERENCE("brand-name-facebook"),
                })),
        FTL.
        Message(
            id=FTL.Identifier("facebook-container-get-the-facebook-container"),
            value=REPLACE(
                index, "Get the Facebook Container Extension", {
                    "Facebook Container":
                    TERM_REFERENCE("brand-name-facebook-container"),
                })),
        FTL.
        Message(
            id=FTL.Identifier("facebook-container-download-firefox-and-get-the"
                              ),
            value=REPLACE(
                index,
                "Download Firefox and get the Facebook Container Extension", {
                    "Facebook Container":
                    TERM_REFERENCE("brand-name-facebook-container"),
                    "Firefox":
                    TERM_REFERENCE("brand-name-firefox"),
                })),
        FTL.
        Message(
            id=FTL.
            Identifier("facebook-container-the-facebook-container-extension"),
            value=REPLACE(
                index,
                "The Facebook Container Extension is not available on mobile devices.",
                {
                    "Facebook Container":
                    TERM_REFERENCE("brand-name-facebook-container"),
                })),
        FTL.
        Message(
            id=FTL.
            Identifier("facebook-container-try-firefox-focus-the-privacy"),
            value=REPLACE(
                index,
                "Try <strong>Firefox Focus</strong>, the privacy browser for Android and iOS.",
                {
                    "Firefox Focus":
                    TERM_REFERENCE("brand-name-firefox-focus"),
                    "Android": TERM_REFERENCE("brand-name-android"),
                    "iOS": TERM_REFERENCE("brand-name-ios"),
                })),
    ] + transforms_from(
        """
facebook-container-opt-out-on-your-terms = {COPY(index, "Opt out on your terms",)}
""",
        index=index
    ) + [
        FTL.Message(
            id=FTL.Identifier("facebook-container-facebook-can-track-almost"),
            value=REPLACE(
                index,
                "Facebook can track almost all your web activity and tie it to your Facebook identity. If that’s too much for you, the <a href=\"%(fbcontainer)s\">Facebook Container extension</a> isolates your identity into a separate container tab, making it harder for Facebook to track you on the web outside of Facebook.",
                {
                    "%%":
                    "%",
                    "%(fbcontainer)s":
                    VARIABLE_REFERENCE("fbcontainer"),
                    "Facebook":
                    TERM_REFERENCE("brand-name-facebook"),
                    "Facebook Container":
                    TERM_REFERENCE("brand-name-facebook-container"),
                })),
    ] + transforms_from(
        """
facebook-container-install-and-contain = {COPY(index, "Install and contain",)}
""",
        index=index
    ) + [
        FTL.Message(
            id=FTL.Identifier(
                "facebook-container-installing-the-extension-is"),
            value=REPLACE(
                index,
                "Installing the <a href=\"%(fbcontainer)s\">extension</a> is easy and, once activated, will open Facebook in a blue tab each time you use it. Use and enjoy Facebook normally. Facebook will still be able to send you advertising and recommendations on their site, but it will be much harder for Facebook to use your activity collected <strong>off Facebook</strong> to send you ads and other targeted messages.",
                {
                    "%%": "%",
                    "%(fbcontainer)s": VARIABLE_REFERENCE("fbcontainer"),
                    "Facebook": TERM_REFERENCE("brand-name-facebook"),
                })),
        FTL.Message(
            id=FTL.Identifier("facebook-container-about-firefox-and-mozilla"),
            value=REPLACE(
                index, "About Firefox and Mozilla", {
                    "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                })),
        FTL.Message(
            id=FTL.Identifier("facebook-container-were-backed-by-mozilla-the"),
            value=REPLACE(
                index,
                "We’re backed by <a href=\"%(mozilla)s\">Mozilla</a>, the not-for-profit organization that puts people over profit to give everyone more power online. We created this extension because we believe that you should have easy-to-use tools that help you manage your privacy and security.",
                {
                    "%%": "%",
                    "%(mozilla)s": VARIABLE_REFERENCE("mozilla"),
                    "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                })),
        FTL.Message(
            id=FTL.Identifier("facebook-container-browse-freely-with-firefox"),
            value=REPLACE(index, "Browse freely with Firefox today.", {
                "Firefox": TERM_REFERENCE("brand-name-firefox"),
            })),
    ])
コード例 #26
0
def migrate(ctx):
    """Migrate bedrock/firefox/templates/firefox/features/password-manager.html, part {index}."""

    ctx.add_transforms(
        "firefox/features/password-manager.ftl",
        "firefox/features/password-manager.ftl", [
            FTL.Message(id=FTL.Identifier("password-manager-firefox-browser"),
                        value=REPLACE(
                            password_manager,
                            "Firefox Browser: Fast, Easy Password Manager", {
                                "Firefox Browser":
                                TERM_REFERENCE("brand-name-firefox-browser"),
                            })),
            FTL.Message(
                id=FTL.Identifier("password-manager-firefox-password"),
                value=REPLACE(
                    password_manager,
                    "Firefox Password Manager saves all your passwords in one place so you can automatically login to sites, or retrieve saved passwords.",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ] + transforms_from("""
password-manager-password-manager = {COPY(password_manager, "Password Manager achievement unlocked",)}
""",
                            password_manager=password_manager) +
        [
            FTL.Message(
                id=FTL.Identifier("password-manager-give-up-the-memory"),
                value=REPLACE(
                    password_manager,
                    "Give up the memory game with Firefox Password Manager.", {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ] + transforms_from("""
password-manager-password-hero = {COPY(password_manager, "Password hero",)}
""",
                            password_manager=password_manager) +
        [
            FTL.Message(
                id=FTL.Identifier("password-manager-forget-the-reset"),
                value=REPLACE(
                    password_manager,
                    "Forget the reset. Firefox Password Manager keeps all your passwords so you can log in automatically, or find saved passwords easily. For super security, give your computer a <a href=\"%(url)s\">master password</a>.",
                    {
                        "%%": "%",
                        "%(url)s": VARIABLE_REFERENCE("url"),
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ] + transforms_from("""
password-manager-password-ninja = {COPY(password_manager, "Password ninja",)}
""",
                            password_manager=password_manager) +
        [
            FTL.Message(
                id=FTL.Identifier("password-manager-no-more-try-again"),
                value=REPLACE(
                    password_manager,
                    "No more “try again” while you’re trying to get somewhere. Log in to your Firefox Account on your phone, and your passwords come with you. Your login details will simply appear, just like that.",
                    {
                        "Firefox Account":
                        TERM_REFERENCE("brand-name-firefox-account"),
                    })),
        ] + transforms_from("""
password-manager-password-master = {COPY(password_manager, "Password master",)}
""",
                            password_manager=password_manager) +
        [
            FTL.Message(
                id=FTL.Identifier("password-manager-earn-your-second"),
                value=REPLACE(
                    password_manager,
                    "Earn your second security black belt with Firefox’s vast array of password manager <a href=\"%(addons)s\">add-ons</a>. Choose an existing favorite or find a next-level one through expert community ratings and reviews.",
                    {
                        "%%": "%",
                        "%(addons)s": VARIABLE_REFERENCE("addons"),
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ])
コード例 #27
0
def migrate(ctx):
    """Bug 1568133 - Migrate remaining menubar from dtd to ftl, part {index}"""

    ctx.add_transforms(
        "browser/browser/menubar.ftl",
        "browser/browser/menubar.ftl",
        transforms_from(
            """
menu-application-services =
    .label = { COPY(base_path, "servicesMenuMac.label") }
menu-application-hide-other =
    .label = { COPY(base_path, "hideOtherAppsCmdMac.label") }
menu-application-show-all =
    .label = { COPY(base_path, "showAllAppsCmdMac.label") }
menu-application-touch-bar =
    .label = { COPY(base_path, "touchBarCmdMac.label") }

menu-quit =
    .label =
        { PLATFORM() ->
            [windows] { COPY(browser_path, "quitApplicationCmdWin2.label") }
           *[other] { COPY(browser_path, "quitApplicationCmd.label") }
        }
    .accesskey =
        { PLATFORM() ->
            [windows] { COPY(browser_path, "quitApplicationCmdWin2.accesskey") }
           *[other] { COPY(browser_path, "quitApplicationCmd.accesskey") }
        }

menu-quit-button =
    .label = { menu-quit.label }
""",
            base_path="browser/chrome/browser/baseMenuOverlay.dtd",
            browser_path="browser/chrome/browser/browser.dtd",
        ),
    )

    ctx.add_transforms(
        "browser/browser/menubar.ftl",
        "browser/browser/menubar.ftl",
        [
            FTL.Message(
                id=FTL.Identifier("menu-application-hide-this"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("label"),
                        value=REPLACE(
                            "browser/chrome/browser/baseMenuOverlay.dtd",
                            "hideThisAppCmdMac2.label",
                            {
                                "&brandShorterName;": TERM_REFERENCE(
                                    "brand-shorter-name"
                                ),
                            },
                        ),
                    )
                ],
            ),
            FTL.Message(
                id=FTL.Identifier("menu-quit-mac"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("label"),
                        value=REPLACE(
                            "browser/chrome/browser/browser.dtd",
                            "quitApplicationCmdMac2.label",
                            {
                                "&brandShorterName;": TERM_REFERENCE(
                                    "brand-shorter-name"
                                ),
                            },
                        ),
                    )
                ],
            ),
            FTL.Message(
                id=FTL.Identifier("menu-quit-button-win"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("label"),
                        value=FTL.Pattern(
                            elements=[
                                FTL.Placeable(
                                    expression=FTL.MessageReference(
                                        id=FTL.Identifier("menu-quit"),
                                        attribute=FTL.Identifier("label"),
                                    )
                                )
                            ]
                        ),
                    ),
                    FTL.Attribute(
                        id=FTL.Identifier("tooltip"),
                        value=REPLACE(
                            "browser/chrome/browser/browser.dtd",
                            "quitApplicationCmdWin2.tooltip",
                            {
                                "&brandShorterName;": TERM_REFERENCE(
                                    "brand-shorter-name"
                                ),
                            },
                        ),
                    ),
                ],
            ),
            FTL.Message(
                id=FTL.Identifier("menu-about"),
                attributes=[
                    FTL.Attribute(
                        id=FTL.Identifier("label"),
                        value=REPLACE(
                            "browser/chrome/browser/baseMenuOverlay.dtd",
                            "aboutProduct2.label",
                            {
                                "&brandShorterName;": TERM_REFERENCE(
                                    "brand-shorter-name"
                                ),
                            },
                        ),
                    ),
                    FTL.Attribute(
                        id=FTL.Identifier("accesskey"),
                        value=COPY(
                            "browser/chrome/browser/baseMenuOverlay.dtd",
                            "aboutProduct2.accesskey",
                        ),
                    ),
                ],
            ),
        ],
    )
コード例 #28
0
def migrate(ctx):
	"""Bug 1549561 - Migrate strings from pipnss.properties to aboutCertError.ftl"""
	ctx.add_transforms(
		'browser/browser/aboutCertError.ftl',
		'browser/browser/aboutCertError.ftl',
        transforms_from(
"""
cert-error-mitm-intro = { COPY(from_path, "certErrorMitM") }
cert-error-trust-unknown-issuer-intro = { COPY(from_path, "certErrorTrust_UnknownIssuer4") }
cert-error-trust-cert-invalid = { COPY(from_path, "certErrorTrust_CaInvalid") }
cert-error-trust-untrusted-issuer = { COPY(from_path, "certErrorTrust_Issuer") }
cert-error-trust-signature-algorithm-disabled = { COPY(from_path, "certErrorTrust_SignatureAlgorithmDisabled") }
cert-error-trust-expired-issuer = { COPY(from_path, "certErrorTrust_ExpiredIssuer") }
cert-error-trust-self-signed = { COPY(from_path, "certErrorTrust_SelfSigned") }
cert-error-trust-symantec = { COPY(from_path, "certErrorTrust_Symantec1") }
cert-error-untrusted-default = { COPY(from_path, "certErrorTrust_Untrusted") }
""", from_path="security/manager/chrome/pipnss/pipnss.properties"))
	ctx.add_transforms(
		'browser/browser/aboutCertError.ftl',
                'browser/browser/aboutCertError.ftl',
		[
			FTL.Message(
				id=FTL.Identifier('cert-error-intro'),
				value=REPLACE(
					'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorIntro',
					{
						"%1$S": VARIABLE_REFERENCE("hostname"),
					},
					normalize_printf=True
				)
			),
			FTL.Message(
				id=FTL.Identifier('cert-error-mitm-mozilla'),
				value=REPLACE(
					'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorMitM2',
					{
						"%1$S": TERM_REFERENCE("brand-short-name"),
					},
					normalize_printf=True
				)
			),
			FTL.Message(
				id=FTL.Identifier('cert-error-mitm-connection'),
				value=REPLACE(
					'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorMitM3',
					{
						"%1$S": TERM_REFERENCE("brand-short-name"),
                                        },
                                        normalize_printf=True
                                )
                        ),
			FTL.Message(
				id=FTL.Identifier('cert-error-trust-unknown-issuer'),
				value=REPLACE(
					'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorTrust_UnknownIssuer6',
					{
						"%1$S": TERM_REFERENCE("brand-short-name"),
						"%2$S": VARIABLE_REFERENCE("hostname"),
					},
					normalize_printf=True
                                )
                        ),
                        FTL.Message(
				id=FTL.Identifier('cert-error-domain-mismatch'),
				value=REPLACE(
					'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorMismatch3',
					{
						"%1$S": TERM_REFERENCE("brand-short-name"),
                                                "%2$S": VARIABLE_REFERENCE("hostname"),
                                        },
                                        normalize_printf=True
                                )
                        ),
			FTL.Message(
                                id=FTL.Identifier('cert-error-domain-mismatch-single-nolink'),
				value=CONCAT(
					REPLACE(
						'security/manager/chrome/pipnss/pipnss.properties',
						'certErrorMismatchSinglePrefix3',
                                        	{
                                                	"%1$S": TERM_REFERENCE("brand-short-name"),
                                        	        "%2$S": VARIABLE_REFERENCE("hostname"),
                                        	},
                                        	normalize_printf=True
                                	),
					FTL.TextElement(' '),
					REPLACE(
						'security/manager/chrome/pipnss/pipnss.properties',
						'certErrorMismatchSinglePrefix',
						{
							"%1$S": VARIABLE_REFERENCE("alt-name"),
						},
						normalize_printf=True
                                        ),
                        	),
			),
			FTL.Message(
                                id=FTL.Identifier('cert-error-domain-mismatch-single'),
				value=CONCAT(
					REPLACE(
                                                'security/manager/chrome/pipnss/pipnss.properties',
                                                'certErrorMismatchSinglePrefix3',
                                                {
                                                        "%1$S": TERM_REFERENCE("brand-short-name"),
                                                        "%2$S": VARIABLE_REFERENCE("hostname"),
                                                },
                                                normalize_printf=True
                                        ),
					FTL.TextElement(' '),
					REPLACE(
                                                'security/manager/chrome/pipnss/pipnss.properties',
                                                'certErrorMismatchSinglePrefix',
                                                {
                                                        "%S": CONCAT(
								FTL.TextElement('<a data-l10n-name="domain-mismatch-link">'),
								VARIABLE_REFERENCE("alt-name"),
								FTL.TextElement('</a>'),
							),
                                                },
                                        ),
				),
			),
			FTL.Message(
                                id=FTL.Identifier('cert-error-domain-mismatch-multiple'),
				value=CONCAT(
					REPLACE(
						'security/manager/chrome/pipnss/pipnss.properties',
						'certErrorMismatchMultiple3',
						{
							"%1$S": TERM_REFERENCE("brand-short-name"),
                                                	"%2$S": VARIABLE_REFERENCE("hostname"),
						},
						normalize_printf=True
                                	),
					FTL.TextElement(' '),
					VARIABLE_REFERENCE("subject-alt-names"),
				),
			),
			FTL.Message(
                                id=FTL.Identifier('cert-error-expired-now'),
				value=REPLACE(
                                        'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorExpiredNow3',
					{
						"%1$S": VARIABLE_REFERENCE("hostname"),
						"%2$S": VARIABLE_REFERENCE("not-after-local-time"),
					},
                                        normalize_printf=True
                                ),
                        ),
			FTL.Message(
                                id=FTL.Identifier('cert-error-not-yet-valid-now'),
				value=REPLACE(
                                        'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorNotYetValidNow3',
					{
						"%1$S": VARIABLE_REFERENCE("hostname"),
                                                "%2$S": VARIABLE_REFERENCE("not-before-local-time"),
					},
                                        normalize_printf=True
                                ),
                        ),
			FTL.Message(
                                id=FTL.Identifier('cert-error-code-prefix-link'),
				value=REPLACE(
                                        'security/manager/chrome/pipnss/pipnss.properties',
					'certErrorCodePrefix3',
					{
						"%1$S": CONCAT(
							FTL.TextElement('<a data-l10n-name="error-code-link">'),
							VARIABLE_REFERENCE("error"),
							FTL.TextElement('</a>'),
						),
					},
					normalize_printf=True
				),
			),
		]
	)
コード例 #29
0
ファイル: thank-you.py プロジェクト: yathu/bedrock
def migrate(ctx):
    """Migrate bedrock/firefox/templates/firefox/retention/thank-you.html, part {index}."""

    ctx.add_transforms(
        "firefox/retention/thank-you.ftl", "firefox/retention/thank-you.ftl",
        transforms_from("""
thank-you-thank-you = {COPY(thank_you, "Thank You",)}
thank-you-thank-you-page = {COPY(thank_you, "Thank you page.",)}
thank-you-its-all-thanks-to-you = {COPY(thank_you, "It’s all thanks to you",)}
""",
                        thank_you=thank_you) +
        [
            FTL.Message(
                id=FTL.Identifier("thank-you-choosing-firefox-helps"),
                value=REPLACE(
                    thank_you,
                    "Choosing Firefox helps Mozilla make the Internet a better place. Here’s what you can do next:",
                    {
                        "Mozilla": TERM_REFERENCE("brand-name-mozilla"),
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
            FTL.Message(
                id=FTL.Identifier("thank-you-make-firefox-your-default"),
                value=REPLACE(thank_you, "Make Firefox your default browser", {
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                })),
        ] + transforms_from("""
thank-you-1-min-action = {COPY(thank_you, "1 min action",)}
thank-you-set-as-your-default = {COPY(thank_you, "Set as your default",)}
""",
                            thank_you=thank_you) +
        [
            FTL.Message(
                id=FTL.Identifier("thank-you-get-firefox-on-your-phone"),
                value=REPLACE(thank_you, "Get Firefox on your phone", {
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                })),
        ] + transforms_from("""
thank-you-2-min-install = {COPY(thank_you, "2 min install",)}
""",
                            thank_you=thank_you) +
        [
            FTL.Message(
                id=FTL.Identifier("thank-you-download-firefox"),
                value=REPLACE(thank_you, "Download Firefox", {
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                })),
            FTL.Message(
                id=FTL.Identifier("thank-you-tell-your-friends-about"),
                value=REPLACE(thank_you, "Tell your friends about Firefox", {
                    "Firefox": TERM_REFERENCE("brand-name-firefox"),
                })),
        ] + transforms_from("""
thank-you-1-min-share = {COPY(thank_you, "1 min share",)}
""",
                            thank_you=thank_you) +
        [
            FTL.Message(
                id=FTL.Identifier("thank-you-join-me-in-the-fight-for"),
                value=REPLACE(
                    thank_you,
                    "Join me in the fight for an open web by choosing Firefox!",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ] + transforms_from("""
thank-you-send-a-tweet = {COPY(thank_you, "Send a tweet",)}
thank-you-make-the-internet-a-safer = {COPY(thank_you, "Make the Internet a safer place",)}
thank-you-4-min-read = {COPY(thank_you, "4 min read",)}
thank-you-stay-in-touch-for-more = {COPY(thank_you, "Stay in touch for more cool stuff",)}
""",
                            thank_you=thank_you) +
        [
            FTL.Message(
                id=FTL.Identifier("thank-you-get-the-latest-greatest"),
                value=REPLACE(
                    thank_you,
                    "Get the latest & greatest from Firefox delivered straight to your inbox.",
                    {
                        "Firefox": TERM_REFERENCE("brand-name-firefox"),
                    })),
        ])
コード例 #30
0
def migrate(ctx):
    """Bug 1491672 - Migrate About Dialog to use Fluent for localization, part {index}."""

    ctx.add_transforms(
        "browser/browser/aboutDialog.ftl", "browser/browser/aboutDialog.ftl",
        transforms_from("""
releaseNotes-link = { COPY("browser/chrome/browser/aboutDialog.dtd", "releaseNotes.link") }

update-checkForUpdatesButton =
    .label = { COPY("browser/chrome/browser/aboutDialog.dtd", "update.checkForUpdatesButton.label") }
    .accesskey = { COPY("browser/chrome/browser/aboutDialog.dtd", "update.checkForUpdatesButton.accesskey") }

update-checkingForUpdates = { COPY("browser/chrome/browser/aboutDialog.dtd", "update.checkingForUpdates")}
update-applying = { COPY("browser/chrome/browser/aboutDialog.dtd", "update.applying")}

update-adminDisabled = { COPY("browser/chrome/browser/aboutDialog.dtd", "update.adminDisabled") }

update-restarting = { COPY("browser/chrome/browser/aboutDialog.dtd", "update.restarting") }

bottomLinks-license = { COPY("browser/chrome/browser/aboutDialog.dtd", "bottomLinks.license") }
bottomLinks-rights = { COPY("browser/chrome/browser/aboutDialog.dtd", "bottomLinks.rights") }
bottomLinks-privacy = { COPY("browser/chrome/browser/aboutDialog.dtd", "bottomLinks.privacy") }

aboutDialog-architecture-sixtyFourBit = { COPY("browser/chrome/browser/browser.properties", "aboutDialog.architecture.sixtyFourBit") }
aboutDialog-architecture-thirtyTwoBit = { COPY("browser/chrome/browser/browser.properties", "aboutDialog.architecture.thirtyTwoBit") }
"""))

    ctx.add_transforms(
        "browser/browser/aboutDialog.ftl", "browser/browser/aboutDialog.ftl", [
            FTL.Message(id=FTL.Identifier("aboutDialog-title"),
                        attributes=[
                            FTL.Attribute(
                                id=FTL.Identifier("title"),
                                value=REPLACE(
                                    "browser/chrome/browser/aboutDialog.dtd",
                                    "aboutDialog.title", {
                                        "&brandFullName;":
                                        TERM_REFERENCE("-brand-full-name")
                                    }))
                        ]),
            FTL.Message(
                id=FTL.Identifier("update-updateButton"),
                attributes=[
                    FTL.Attribute(id=FTL.Identifier("label"),
                                  value=REPLACE(
                                      "browser/chrome/browser/aboutDialog.dtd",
                                      "update.updateButton.label3", {
                                          "&brandShorterName;":
                                          TERM_REFERENCE("-brand-shorter-name")
                                      })),
                    FTL.Attribute(id=FTL.Identifier("accesskey"),
                                  value=COPY(
                                      "browser/chrome/browser/aboutDialog.dtd",
                                      "update.updateButton.accesskey"))
                ]),
            FTL.Message(id=FTL.Identifier("update-downloading"),
                        value=CONCAT(
                            FTL.TextElement('<img data-l10n-name="icon"/>'),
                            COPY("browser/chrome/browser/aboutDialog.dtd",
                                 "update.downloading.start"),
                            FTL.TextElement(
                                '<label data-l10n-name="download-status"/>'))),
            FTL.Message(
                id=FTL.Identifier("update-failed"),
                value=CONCAT(
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "update.failed.start"),
                    FTL.TextElement('<label data-l10n-name="failed-link">'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "update.failed.linkText"),
                    FTL.TextElement('</label>'))),
            FTL.Message(
                id=FTL.Identifier("update-failed-main"),
                value=CONCAT(
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "update.failed.start"),
                    FTL.TextElement('<a data-l10n-name="failed-link-main">'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "update.failed.linkText"), FTL.TextElement('</a>'))),
            FTL.Message(
                id=FTL.Identifier("update-noUpdatesFound"),
                value=REPLACE(
                    "browser/chrome/browser/aboutDialog.dtd",
                    "update.noUpdatesFound",
                    {"&brandShortName;": TERM_REFERENCE("-brand-short-name")
                     })),
            FTL.Message(
                id=FTL.Identifier("update-otherInstanceHandlingUpdates"),
                value=REPLACE(
                    "browser/chrome/browser/aboutDialog.dtd",
                    "update.otherInstanceHandlingUpdates",
                    {"&brandShortName;": TERM_REFERENCE("-brand-short-name")
                     })),
            FTL.Message(
                id=FTL.Identifier("update-manual"),
                value=CONCAT(
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "update.manual.start"),
                    FTL.TextElement('<label data-l10n-name="manual-link"/>'))),
            FTL.Message(id=FTL.Identifier("update-unsupported"),
                        value=CONCAT(
                            COPY("browser/chrome/browser/aboutDialog.dtd",
                                 "update.unsupported.start"),
                            FTL.TextElement(
                                '<label data-l10n-name="unsupported-link">'),
                            COPY("browser/chrome/browser/aboutDialog.dtd",
                                 "update.unsupported.linkText"),
                            FTL.TextElement('</label>'))),
            FTL.Message(
                id=FTL.Identifier("channel-description"),
                value=CONCAT(
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "channel.description.start"),
                    FTL.TextElement(
                        '<label data-l10n-name="current-channel"></label>'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "channel.description.end"))),
            FTL.Message(
                id=FTL.Identifier("warningDesc-version"),
                value=REPLACE(
                    "browser/chrome/browser/aboutDialog.dtd",
                    "warningDesc.version",
                    {"&brandShortName;": TERM_REFERENCE("-brand-short-name")
                     })),
            FTL.Message(
                id=FTL.Identifier("community-exp"),
                value=CONCAT(
                    FTL.TextElement(
                        '<label data-l10n-name="community-exp-mozillaLink">'),
                    REPLACE("browser/chrome/browser/aboutDialog.dtd",
                            "community.exp.mozillaLink", {
                                "&vendorShortName;":
                                TERM_REFERENCE("-vendor-short-name")
                            }), FTL.TextElement('</label>'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "community.exp.middle"),
                    FTL.TextElement(
                        '<label data-l10n-name="community-exp-creditsLink">'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "community.exp.creditsLink"),
                    FTL.TextElement('</label>'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "community.exp.end"))),
            FTL.Message(
                id=FTL.Identifier("community-2"),
                value=CONCAT(
                    REPLACE("browser/chrome/browser/aboutDialog.dtd",
                            "community.start2", {
                                "&brandShortName;":
                                TERM_REFERENCE("-brand-short-name")
                            }),
                    FTL.TextElement(
                        '<label data-l10n-name="community-mozillaLink">'),
                    REPLACE("browser/chrome/browser/aboutDialog.dtd",
                            "community.mozillaLink", {
                                "&vendorShortName;":
                                TERM_REFERENCE("-vendor-short-name")
                            }), FTL.TextElement('</label>'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "community.middle2"),
                    FTL.TextElement(
                        '<label data-l10n-name="community-creditsLink">'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "community.creditsLink"), FTL.TextElement('</label>'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "community.end3"))),
            FTL.Message(
                id=FTL.Identifier("helpus"),
                value=CONCAT(
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "helpus.start"),
                    FTL.TextElement(
                        '<label data-l10n-name="helpus-donateLink">'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "helpus.donateLink"), FTL.TextElement('</label>'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "helpus.middle"),
                    FTL.TextElement(
                        '<label data-l10n-name="helpus-getInvolvedLink">'),
                    COPY("browser/chrome/browser/aboutDialog.dtd",
                         "helpus.getInvolvedLink"),
                    FTL.TextElement('</label>'))),
        ])
    ctx.add_transforms(
        "browser/branding/official/brand.ftl",
        "browser/branding/official/brand.ftl",
        transforms_from("""
-brand-short-name = { COPY("browser/branding/official/brand.dtd", "brandShortName") }
-vendor-short-name = { COPY("browser/branding/official/brand.dtd", "vendorShortName") }
-brand-full-name = { COPY("browser/branding/official/brand.dtd", "brandFullName") }
-brand-shorter-name = { COPY("browser/branding/official/brand.dtd", "brandShorterName") }
trademarkInfo = { COPY("browser/branding/official/brand.dtd", "trademarkInfo.part1") }

"""))