Skip to content

Commit

Permalink
Fix spinner margins (#196)
Browse files Browse the repository at this point in the history
  • Loading branch information
edan-bainglass authored Jan 31, 2025
1 parent cd27871 commit ca8d209
Showing 1 changed file with 16 additions and 9 deletions.
25 changes: 16 additions & 9 deletions code_setup.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,16 @@
" super().__init__(\n",
" children=[\n",
" ipw.Label(message),\n",
" ipw.HTML(\"<i class='fa fa-spinner fa-spin fa-2x fa-fw'/>\"),\n",
" ipw.HTML(\n",
" value=\"<i class='fa fa-spinner fa-spin fa-2x fa-fw'/>\",\n",
" layout=ipw.Layout(margin=\"12px 0 6px\"),\n",
" ),\n",
" ],\n",
" layout=ipw.Layout(justify_content=\"center\"),\n",
" layout=ipw.Layout(\n",
" justify_content=\"center\",\n",
" align_items=\"center\",\n",
" **kwargs.pop(\"layout\", {}),\n",
" ),\n",
" **kwargs,\n",
" )\n",
" self.add_class(\"loading\")"
Expand Down Expand Up @@ -210,15 +217,15 @@
"metadata": {},
"outputs": [],
"source": [
"# def on_code_setup_message_change(change):\n",
"# if \"created\" in change[\"new\"]:\n",
"# render()\n",
"def on_code_setup_message_change(change):\n",
" if \"created\" in change[\"new\"]:\n",
" render()\n",
"\n",
"\n",
"# widget.aiida_code_setup.observe(\n",
"# on_code_setup_message_change,\n",
"# \"message\",\n",
"# )"
"widget.aiida_code_setup.observe(\n",
" on_code_setup_message_change,\n",
" \"message\",\n",
")"
]
}
],
Expand Down

0 comments on commit ca8d209

Please sign in to comment.