.PHONY: upgrade-pollination-react

.PHONY: generate-frontend

.PHONY: uninstall

upgrade-pollination-react:
	yarn --cwd pollination_streamlit_io/select_study/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/select_run/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/select_account/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/select_project/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/select_recipe/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/auth_user/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/get_geometry/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/get_hbjson/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/get_host/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/send_geometry/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/send_hbjson/frontend add pollination-react-io@latest
	yarn --cwd pollination_streamlit_io/send_results/frontend add pollination-react-io@latest

generate-frontend:
	yarn --cwd pollination_streamlit_io/select_study/frontend build
	yarn --cwd pollination_streamlit_io/select_run/frontend build
	yarn --cwd pollination_streamlit_io/select_account/frontend build
	yarn --cwd pollination_streamlit_io/select_project/frontend build
	yarn --cwd pollination_streamlit_io/select_recipe/frontend build
	yarn --cwd pollination_streamlit_io/auth_user/frontend build
	yarn --cwd pollination_streamlit_io/get_geometry/frontend build
	yarn --cwd pollination_streamlit_io/get_hbjson/frontend build
	yarn --cwd pollination_streamlit_io/get_host/frontend build
	yarn --cwd pollination_streamlit_io/send_geometry/frontend build
	yarn --cwd pollination_streamlit_io/send_hbjson/frontend build
	yarn --cwd pollination_streamlit_io/send_results/frontend build

uninstall: 
	yarn --cwd pollination_streamlit_io/auth_user/frontend remove browserify-zlib buffer fs-browser https-browserify os-browserify path-browserify stream-browserify stream-http tty-browserify url node-polyfill-webpack-plugin
	yarn --cwd pollination_streamlit_io/get_geometry/frontend remove browserify-zlib buffer fs-browser https-browserify os-browserify path-browserify stream-browserify stream-http tty-browserify url node-polyfill-webpack-plugin
	yarn --cwd pollination_streamlit_io/get_hbjson/frontend remove browserify-zlib buffer fs-browser https-browserify os-browserify path-browserify stream-browserify stream-http tty-browserify url node-polyfill-webpack-plugin
	yarn --cwd pollination_streamlit_io/get_host/frontend remove browserify-zlib buffer fs-browser https-browserify os-browserify path-browserify stream-browserify stream-http tty-browserify url node-polyfill-webpack-plugin
	yarn --cwd pollination_streamlit_io/send_geometry/frontend remove browserify-zlib buffer fs-browser https-browserify os-browserify path-browserify stream-browserify stream-http tty-browserify url node-polyfill-webpack-plugin
	yarn --cwd pollination_streamlit_io/send_hbjson/frontend remove browserify-zlib buffer fs-browser https-browserify os-browserify path-browserify stream-browserify stream-http tty-browserify url node-polyfill-webpack-plugin
	yarn --cwd pollination_streamlit_io/send_results/frontend remove browserify-zlib buffer fs-browser https-browserify os-browserify path-browserify stream-browserify stream-http tty-browserify url node-polyfill-webpack-plugin