CSS/SCSS changes to code not applying in browser - html

I am trying to hide a number by modifying the scss/css. It is the tag in the picture: poll-row__number.
Strange thing is also it is not in the scss file the inspector is showing but another.
I am running an Adhocracy installation (Nginx on Ubuntu Linux) in a virtual environment. I changed all the poll-row__number references in css/ scss files to display:none / visibility:hidden. Rebooted the server and deleted my cache from my browser, tried Chrome, FireFox and Safari. But the number stays visible. When I change it in the inspector, it dissapears.
This is my css directory with files
The poll-row__number is in _poll.scss like here
As you can see the value display:none/ visibility:hidden is added.
When grepping the div it finds nothing systemwide. When grepping the pol-row__number it finds it, but everything it finds is changed to display:none/ visibility:hidden.
What am I doing wrong and what else do you want for information to help me fix this strange ptoblem.
I tried all I can think of.

There's not much of code you're showing us. So it'll be hard to find the error.
Try to add display: none; in the console (web browser)
First make sure the scss is translated to the css file :
sass --watch src/scss/_project_header.scss:src/css/_project_header.css
Second, verify that the .poll-row__number is not used in another css file linked to you html file because as we can see the current display is inline-block.
Then, check if you don't use twice .poll-row__number because the basic css rule is the following, the last property stated is the one that overlaps the others, example :
CSS
.poll-row__number{
display :none;
}
.poll-row__number{
display :inline-block;
}
There, .poll-row__number will get inline-block. And I just saw that you have this issue in your code (or was it on purpose) :
Line 1 : .poll-row__number (has no display property)
Line 2 : .poll-row__number, .poll-row__label (has display inline-block)
(It is my opinion but using "__" for ids or class is ugly and confusing. Please stop it: either use "CamelCase" or just use one "_")

Thanks for all the help. I found the solution. Maybe obvious for a lot of developers, but I am not a pro in this sence.
What I did:
I changed the css/scss files that I wanted to change.
Then I went to my virtual environment and did:
npm install npm run build:prod
pip install --upgrade -r requirements.txt
export DJANGO_SETTINGS_MODULE=adhocracy-plus.config.settings.build
python manage.py compilemessages
python manage.py collectstatic
I do not know if they all are needed, but I figured, maybe the css/scss is build and stored somewhere and then called so it overrides the css file in the projectfolder.
After this I restarted my processes:
sudo systemctl
restart Adhocracy-plus
sudo systemctl restart Adhocracy-plus.service
sudo systemctl restart Adhocracy-plus-background-task
sudo systemctl restart nginx
Then it worked.
In conclusion:
CSS/SCSS is compiled. So changed the CSS/SCSS, recompiled/ build the project ,restarted the services.

Related

PhpStorm not detecting file changes until focussing on another app

Been running into some issues with PhpStorm (v2020.3 on MacOS Big Sur 11.1) lately.
If I make changes to a file and save them, it doesn't trigger actions like a file transfer or recompiling (S)CSS when running npm run watch.
As soon as I focus another application (e.g. the browser for previewing) it detects the changed file and runs the needed action. This causes an annoying delay in my workflow.
At first I thought it had to do with Docker not updating the files in the container, however I now figured out it also does not work with a simple automated (s)FTP file upload/deplyoment.
Anyone else experiencing the same issue?
Cheers,
Allard
Fixed it by remapping the Save document shortcut under Preferences > Keymap. No idea how the shortcut got messed up, but hey, it works.

How to install colortheme in NeoVim in Mac OS X?

I just installed NeoVim VimR 0.13.1 from https://github.com/qvacua/vimr/releases
for Mac OSX. I was able to set default options by creating a file at
~/.config/nvim/init.vim
Now I am having a hard time trying use a color theme. For example I am interested with OceanicNext theme from https://github.com/mhartington/oceanic-next
So I downloaded the zip file, unzipped it then it creates a folder called
oceanic-next-master
So I moved this folder to
~/.config/nvim/oceanic-next-master
Added necessary code to the init.vim file
" For Neovim 0.1.3 and 0.1.4
let $NVIM_TUI_ENABLE_TRUE_COLOR=1
" Or if you have Neovim >= 0.1.5
if (has("termguicolors"))
set termguicolors
endif
" Theme
syntax enable
colorscheme OceanicNext
But even restarting the VimR, nothing happens. So I tried renaming the folder name from
~/.config/nvim/oceanic-next-master
to
~/.config/nvim/OceanicNext
Still no luck. So tried to copy the actual OceanicNext.vim file to
~/.config/nvim/OceanicNext.vim
Still didn't work restarting it. So I tried running the command directly
colorscheme OceanicNext
But it give me the following error message
Cannot find color scheme 'OceanicNext'
I also tried install other color scheme from https://github.com/frankier/neovim-colors-solarized-truecolor-only but still wasn't able to make it work.
I also have MacVim installed and just copy and pasting the plugins into the ~/.vim worked, but looks like NeoVim is different? What am I doing wrong?
Thank you.
The nvim documentation on the colorscheme command :help colorscheme
:colo[rscheme] {name}
Load color scheme {name}. This searches 'runtimepath' for the file
"colors/{name}.vim". The first one that is found is loaded. Also
searches all plugins in 'packpath', first below "start" and then under
"opt".
You can put the color scheme file into ~/.config/nvim/colors f older. Where ~ is your user home directory.
Consider you have "nord.vim" colorscheme. The full path to it will be ~/.config/nvim/colors/nord.vim.
Then the :colorscheme nord command will be able to load the theme.
By the way, vim-plug plugin is great for managing vim and neovim plugins and colorschemes. It will install/update/delete plugins including colorschemes for you. Give it a try.
Had to install vim-plug manager from https://github.com/junegunn/vim-plug
by placing the plug.vim file to
~/.config/nvim/autoload
to install the plugins.

Configure Sublime Text 3 GIT Path

I keep getting an "Executable '['git']' was not found in PATH. Current PATH" error message when trying GIT STATUS in Sublime Text 3. I have the SublimeGit plugin installed.
I have the following in my Package Settings > Settings - User
"git_executables": {
"git": ["/usr/local/bin/git"],
"git_flow": ["/usr/local/bin/git", "flow"],
"legit": ["legit"]
}
I have read https://docs.sublimegit.net/quickstart.html, but it does not go through windows paths.
Any help would be appreciated.
That error message can happen because of operations on a missing or moved file:
See issue 212 (for ST2, but possibly relevant for ST3).
Ok, I think why this bug happened.
There was a file that was moved to another location form outside ST2, and Git plugin failed to do something to the file because it no longer existed, but that situation was interpreted as missing git command.
Another workaround mentions:
Installing python via homebrew and restarting ST2 fixed this problem for me:
brew install python
Also, by David Gee -- davidagee :
On OS X Mountain Lion, the only way I was able to fix this, after trying everything in this thread, and additional mucking around with path settings, was to open "/Users/[me]/Library/Application Support/Sublime Text 2/Packages/Git/Git.sublime-settings" and to change git_command to "/usr/local/git/bin/git".
Adding a git_command setting to user prefs doesn't work.
The plugin seems to ignore the value when set in Preferences.sublime-settings.

How to make MacVim launch with the -y option by default?

Right now I have to go to a terminal and type: "mvim -y &".
I want to be able to launch MacVim with -y option enabled even when clicking on the .app icon or when launching it through the "Open with..." context menu.
I know about the gvimrc and vimrc files under MacVim.app/Contents/Resources/vim, so I just need someone to tell me what to add in which file.
Thanks a lot.
I believe you should be able to add set insertmode to either your .vimrc or .gvmirc files.
If you are setting this because it is your personal preference, you might consider adding the line to the .gvim file in your home directory instead. Modifying the configuration of the application it's self would probably affect other users on the machine.

ipfw resetting after reboot

I added a rule in my ipfw a time ago and now I want to delete it. So i go:
sudo ipfw flush
And all user rules gets deleted. But everytime i restart the machine the rule is back again!
I tried looking for some ipfw config file, but has not find anything. When I added the rule the first time i user WaterRoof (frontend for ipfw), could that have somthing to do with this? (I also tried removing the rule with WaterRoof, but same result)
Any ideas on where this rule gets added every time? I don't know where to start.
Im running OS X 10.6
Hmpf... It was Internet Sharing that added the rule, when I turned it of it all went back to normal.
Should be the same for OSX. Run:
cat /etc/rc.conf |grep -i "firewall"
You should see:
firewall_script="/etc/ipfw.rules"
Modify whatever file that parameter is using.