-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
951c41c
commit db83a53
Showing
4 changed files
with
45 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export PYTHONPATH=$PYTHONPATH:. | ||
marimo run title_case_marimo.py --port=2719 --headless |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import marimo | ||
|
||
|
||
__generated_with = "0.1.5" | ||
app = marimo.App() | ||
|
||
|
||
@app.cell | ||
def __(): | ||
import marimo as mo | ||
return mo, | ||
|
||
|
||
@app.cell | ||
def __(mo): | ||
mo.md("# Title Case Demonstration").left() | ||
return | ||
|
||
|
||
@app.cell | ||
def __(mo): | ||
text = mo.ui.text(placeholder="Enter text ...", label="Headline:", full_width=True) | ||
return text, | ||
|
||
@app.cell | ||
def __(mo, text): | ||
import text_conversion | ||
result = text_conversion.title_case(text.value) | ||
|
||
return result | ||
|
||
|
||
@app.cell | ||
def __(mo, text, result): | ||
mo.vstack([text, mo.md(f"Result: \"{result}\"")]) | ||
return | ||
|
||
|
||
if __name__ == "__main__": | ||
app.run() |