import*as i18n from"../i18n/i18n.js";import{Issue,IssueCategory}from"./Issue.js";const UIStrings={preventingMixedContent:"Preventing mixed content",blocked:"blocked",automaticallyUpgraded:"automatically upgraded",warned:"warned"},str_=i18n.i18n.registerUIStrings("sdk/MixedContentIssue.js",UIStrings),i18nString=i18n.i18n.getLocalizedString.bind(void 0,str_),i18nLazyString=i18n.i18n.getLazilyComputedLocalizedString.bind(void 0,str_);export class MixedContentIssue extends Issue{constructor(t,e){super(Protocol.Audits.InspectorIssueCode.MixedContentIssue,e),this._issueDetails=t}static translateStatus(t){const e=mixedContentStatus.get(t);return e?e():t}requests(){return this._issueDetails.request?[this._issueDetails.request]:[]}getDetails(){return this._issueDetails}getCategory(){return IssueCategory.MixedContent}getDescription(){return{file:"issues/descriptions/mixedContent.md",substitutions:void 0,links:[{link:"https://web.dev/what-is-mixed-content/",linkTitle:i18nString(UIStrings.preventingMixedContent)}]}}primaryKey(){return JSON.stringify(this._issueDetails)}}const mixedContentStatus=new Map([["MixedContentBlocked",i18nLazyString(UIStrings.blocked)],["MixedContentAutomaticallyUpgraded",i18nLazyString(UIStrings.automaticallyUpgraded)],["MixedContentWarning",i18nLazyString(UIStrings.warned)]]);