import marimo

__generated_with = "0.0.0"
app = marimo.App(app_title="Casually malicious md")


@app.cell
def _(mo):
    mo.md(
        r"""
        What happens if I just leave a \"\"\"
        " ' ! @ # $ % ^ & * ( ) + = - _ [ ] { } | \ /

        # Notebook
        <!--
        \
        """
    )
    return


@app.cell
def _():
    print("Hello, World!")
    return


@app.cell
def _(mo):
    mo.md(
        r"""
        -->

        ```marimo run convert document.md```
        """
    )
    return


app._unparsable_cell(
    r"""
    it's an unparsable cell
    """,
    name="_"
)


@app.cell
def _(mo):
    mo.md(
        r"""
        <!-- Actually markdown -->
        ```{python} `
          print("Hello, World!")

        <!-- Disabled code block -->
        """
    )
    return


@app.cell(disabled=True)
def _():
    1 + 1
    return


@app.cell
def _(mo):
    mo.md(
        r"""
        <!-- Hidden code block -->
        """
    )
    return


@app.cell(hide_code=True)
def _():
    1 + 1
    return


@app.cell
def _(mo):
    mo.md(
        r"""
        <!-- Empty code block -->
        """
    )
    return


@app.cell
def _():
    return


@app.cell
def _(mo):
    mo.md(
        r"""
        <!-- Improperly nested code block -->
        """
    )
    return


app._unparsable_cell(
    r"""
    \"\"\"
    ```{python}
    print(\"Hello, World!\")
    """,
    name="_"
)


@app.cell
def _(mo):
    mo.md(
        r"""
        \"\"\"
        ```

        <!-- Improperly nested code block -->
        ```{python}
        ````{python}
        print("Hello, World!")
        ````
        ```

        -->

        <!-- from the notebook, should remain unchanged -->
        """
    )
    return


@app.cell
def _(mo):
    mo.md("""
      This is a markdown cell with an execution block in it
      ```{python}
      # To ambiguous to convert
      ```
      """)
    return


@app.cell
def _():
    return


if __name__ == "__main__":
    app.run()