You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: no_type_only_import_attributes.rs
    path of file: ./repos/biome/crates/biome_js_analyze/src/syntax/nursery
    
    the code of the file until where you have to start completion: use biome_analyze::{context::RuleContext, declare_rule, Ast, Rule, RuleDiagnostic};
use biome_console::markup;
use biome_js_syntax::{
    AnyJsExportClause, AnyJsImportClause, AnyJsModuleItem, JsNamedImportSpecifiers, JsSyntaxToken,
};
use biome_rowan::{AstNode, AstSeparatedList, TextRange};

declare_rule! {
    /// Disallow type-only imports and exports with import attributes.
    ///
    /// ## Examples
    ///
    /// ```js
    /// import type { A } from "./a.json" with { type: "json" };
    /// ```
    pub NoTypeOnlyImportAttributes {
        version: "1.5.0",
        name: "noTypeOnlyImportAttributes",
    }
}

impl Rule for NoTypeOnlyImportAttributes {
    type Query = Ast<AnyJsModuleItem>;
    type State = RuleState;
    type Signals = Option<Self::State>;
    type Options = ();

    fn run(ctx: &RuleContext<Self>) -> Self::Signals {
        let module_item = ctx.query();
        match module_item {
            AnyJsModuleItem::AnyJsStatement(_) => None,
            AnyJsModuleItem::JsExport(export) => match export.export_clause().ok()? {
                AnyJsExportClause::AnyJsDeclarationClause(_)
                | AnyJsExportClause::JsExportDefaultDeclarationClause(_)
                | AnyJsExportClause::JsExportDefaultExpressionClause(_)
                | AnyJsExportClause::JsExportNamedClause(_)
                | AnyJsExportClause::TsExportAsNamespaceClause(_)
                | AnyJsExportClause::TsExportAssignmentClause(_)
                | AnyJsExportClause::TsExportDeclareClause(_) => None,
                AnyJsExportClause::JsExportFromClause(clause) => Some(RuleState {
                    assertion_range: clause.assertion()?.range(),
                    type_token_range: clause.type_token()?.text_trimmed_range(),
                }),
                AnyJsExportClause::JsExportNamedFromClause(clause) => {
                    let assertion_range = clause.assertion()?.range();
                    let type_token = clause.type_token().or_else(|| {
                        clause
                            .specifiers()
                            .iter()
                            .filter_map(|specifier| specifier.ok())
                            .find_map(|specifier| specifier.type_token())
                    })?;
                    Some(RuleState {
                        assertion_range,
                        type_token_range: type_token.text_trimmed_range(),
                    })
                }
            },
            AnyJsModuleItem::JsImport(import) => match import.import_clause().ok()? {
                AnyJsImportClause::JsImportBareClause(_) => None,
                AnyJsImportClause::JsImportCombinedClause(clause) => {
                    let assertion_range = clause.assertion()?.range();
                    let type_token =
    
    fn run(ctx: &RuleContext<Self>) -> Self::Signals {
        let module_item = ctx.query();
        match module_item {
            AnyJsModuleItem::AnyJsStatement(_) => None,
            AnyJsModuleItem::JsExport(export) => match export.export_clause().ok()? {
                AnyJsExportClause::AnyJsDeclarationClause(_)
                | AnyJsExportClause::JsExportDefaultDeclarationClause(_)
                | AnyJsExportClause::JsExportDefaultExpressionClause(_)
                | AnyJsExportClause::JsExportNamedClause(_)
                | AnyJsExportClause::TsExportAsNamespaceClause(_)
                | AnyJsExportClause::TsExportAssignmentClause(_)
                | AnyJsExportClause::TsExportDeclareClause(_) => None,
                AnyJsExportClause::JsExportFromClause(clause) => Some(RuleState {
                    assertion_range: clause.assertion()?.range(),
                    type_token_range: clause.type_token()?.text_trimmed_range(),
                }),
                AnyJsExportClause::JsExportNamedFromClause(clause) => {
                    let assertion_range = clause.assertion()?.range();
                    let type_token = clause.type_token().or_else(|| {
                        clause
                            .specifiers()
                            .iter()
                            .filter_map(|specifier| specifier.ok())
                            .find_map(|specifier| specifier.type_token())
                    })?;
                    Some(RuleState {
                        assertion_range,
                        type_token_range: type_token.text_trimmed_range(),
                    })
                }
            },
            AnyJsModuleItem::JsImport(import) => match import.import_clause().ok()? {
                AnyJsImportClause::JsImportBareClause(_) => None,
                AnyJsImportClause::JsImportCombinedClause(clause) => {
                    let assertion_range = clause.assertion()?.range();
                    let type_token = find_first_type_token(
                        clause.specifier().ok()?.as_js_named_import_specifiers()?,
                    )?;
                    Some(RuleState {
                        assertion_range,
                        type_token_range: type_token.text_trimmed_range(),
                    })
                }
                AnyJsImportClause::JsImportDefaultClause(clause) => Some(RuleState {
                    assertion_range: clause.assertion()?.range(),
                    type_token_range: clause.type_token()?.text_trimmed_range(),
                }),
                AnyJsImportClause::JsImportNamedClause(clause) => {
                    let assertion_range = clause.assertion()?.range();
                    let type_token = clause
                        .type_token()
                        .or_else(|| find_first_type_token(&clause.named_specifiers().ok()?))?;
                    Some(RuleState {
                        assertion_range,
                        type_token_range: type_token.text_trimmed_range(),
                    })
                }
                AnyJsImportClause::JsImportNamespaceClause(clause) => Some(RuleState {
                    assertion_range: clause.assertion()?.range(),
                    type_token_range: clause.type_token()?.text_trimmed_range(),
                }),
            },
        }
    }