Delete rows from user created table in Shiny

shiny
dt

#1

I have the following Shiny App:

library(shiny)
library(tidyverse)
library(janitor)
library(DT)

first_df1 <- data.frame(Name = c("John", "Ringo", "George", "Paul"),
                        Partner = c("Yoko", "Maureen", "Pattie", "Linda"))

ui <- fluidPage(
  fluidRow(
    column(4, 
           selectizeInput("Name",
                          label = "Choose a name:",
                          choices = c("John", "Ringo", "George", "Paul")),
           numericInput("Age", "Age:",
                        value = 1,
                        min = 0),
           textInput("Team", "Team:"),
           checkboxInput("Type", "National"),
           textInput("Observation", "Observation"),
           actionButton("submit", "Register")),
    
    column(8,
           DTOutput("table1"),
           tags$br(),
           actionButton("deleteRows", "Delete Rows"))))

server <- function(input, output){
  
  my_df <- reactiveVal(data.frame(Name = NA,
                                  Age = NA,
                                  Team = NA,
                                  Type = NA,
                                  Observation = NA))
  
  cadastro1 <- reactive({
    data.frame(Name = input$Name,
               Age = input$Age,
               Team = input$Team,
               Type = input$Type,
               Observation = input$Observation)
  })
  
  observeEvent(input$submit, {
    my_df(rbind(my_df(), cadastro1()))
  })
  
    
  df_final <- reactive({
    my_df() %>%
      remove_empty("rows") %>%
      mutate(Name = as.character(Name),
             Type = case_when(
               Type == FALSE ~ "International",
               TRUE ~ "National"
             )) %>%
      left_join(first_df1) %>%
      select(Partner, everything())
  })
  
  output$table1 <- renderDT({
    df_final()
  })
  

} 

shinyApp(ui, server)

How can I delete the rows selected in DT (using the Delete Rows button)? I've tried everything but just can't figure it out. Any help is welcome.

Thanks in advance!