Laptop display does not show up on arandr after booting into i3 (nvidia-drivers)

Hi, newbie fedora user here.

Over the past few days, I wanted to be able to close the lid of my computer and use the monitor plugged into my laptop. So I changed HandleLidSwitch=ignore, and I worked with arandr settings and disabled the laptop screen, got the script and added it into my i3 configs. Now I wish to use the laptop disconnected from the monitor. I removed the line for arandr in my configs.

Before all of this, I was able to view the grub windows boot manager screen and luks password screen on my laptop screen and as soon as sddm started my laptop screen when off and it booted on. It still is the same, I’ve looked at the grub.confs and they are no video options. I was able to understand that the error was in nvidia kernel-drivers and modules because once I enabled secure boot kernel loaded nouveau drivers instead of nvidia and it started up on the screen. I do remember changing a couple of settings in the nvidia, i enabled “PrimaryGPU”.

$ xrandr
Screen 0: minimum 8 x 8, current 2560 x 1440, maximum 32767 x 32767
HDMI-0 connected primary 2560x1440+0+0 (normal left inverted right x axis y axis) 597mm x 336mm
   2560x1440     59.95*+  74.99  
   1920x1080     60.00    59.94    50.00    29.97  
   1680x1050     59.95  
   1440x900      59.89  
   1280x1024     75.02    60.02  
   1280x960      60.00  
   1280x720      60.00    59.94    50.00  
   1024x768      75.03    70.07    60.00  
   800x600       75.00    72.19    60.32    56.25  
   720x576       50.00  
   720x480       59.94  
   640x480       75.00    72.81    59.94    59.93  
DP-0 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
$ cat /etc/X11/xorg.conf.d/nvidia.conf
   1   │ #This file is provided by xorg-x11-drv-nvidia
   2   │ #Do not edit
   3   │ 
   4   │ Section "OutputClass"
   5   │     Identifier "nvidia"
   6   │     MatchDriver "nvidia-drm"
   7   │     Driver "nvidia"
   8   │     Option "AllowEmptyInitialConfiguration"
   9   │     Option "SLI" "Auto"
  10   │     Option "BaseMosaic" "on"
  11   │     # Option "PrimaryGPU" "yes"
  12   │ EndSection
  13   │ 
  14   │ Section "ServerLayout"
  15   │     Identifier "layout"
  16   │     Option "AllowNVIDIAGPUScreens"
  17   │     # Option "PrimaryGPU" "yes" 
  18   │ EndSection
$ cat ~/.config/monitors.xml
   1   │ <monitors version="2">
   2   │   <configuration>
   3   │     <logicalmonitor>
   4   │       <x>0</x>
   5   │       <y>0</y>
   6   │       <scale>1</scale>
   7   │       <primary>yes</primary>
   8   │       <monitor>
   9   │         <monitorspec>
  10   │           <connector>eDP</connector>
  11   │           <vendor>AUO</vendor>
  12   │           <product>0xb49b</product>
  13   │           <serial>0x00000000</serial>
  14   │         </monitorspec>
  15   │         <mode>
  16   │           <width>1920</width>
  17   │           <height>1080</height>
  18   │           <rate>165.01383972167969</rate>
  19   │         </mode>
  20   │       </monitor>
  21   │     </logicalmonitor>
  22   │     <logicalmonitor>
  23   │       <x>1920</x>
  24   │       <y>0</y>
  25   │       <scale>1</scale>
  26   │       <monitor>
  27   │         <monitorspec>
  28   │           <connector>HDMI-1-0</connector>
  29   │           <vendor>ACR</vendor>
  30   │           <product>KW272U</product>
  31   │           <serial>1127148014200</serial>
  32   │         </monitorspec>
  33   │         <mode>
  34   │           <width>2560</width>
  35   │           <height>1440</height>
  36   │           <rate>59.950550079345703</rate>
  37   │         </mode>
  38   │       </monitor>
  39   │     </logicalmonitor>
  40   │   </configuration>
  41   │ </monitors>